Re: Domain Name
From: Michael Tissington (michael_at_nospam.com)
Date: 05/10/04
- Next message: Michael Tissington: "Returning Somthing unique about the machine"
- Previous message: Raymond D'Anjou \(raydan\): "Re: Encryption"
- In reply to: Michael Cheng [MSFT]: "Re: Domain Name"
- Next in thread: Michael Cheng [MSFT]: "Re: Domain Name"
- Reply: Michael Cheng [MSFT]: "Re: Domain Name"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 10 May 2004 10:42:06 -0700
Thanks.
Is there anyway of issuing some SQL to return the information from the
server.
(or something else that uniquely identifies the machine)
-- Michael Tissington http://www.oaklodge.com http://www.tabtag.com ""Michael Cheng [MSFT]"" <v-mingqc@online.microsoft.com> wrote in message news:RFHjvkmNEHA.3808@cpmsftngxa10.phx.gbl... > Hi Michael, > > Based on my knowledge, it would be difficult to get NetBIOS name from SQL > Server. However, you could have this as a workaroung > > 1. You must have permission on client. > 2. You shold make a VBS file (for example, named getNetBIOS.vbs) > ======= > strComputer = "clientComputerName" > Set objWMIService = GetObject _ > ("winmgmts:" & "!\\" & strComputer & "\root\cimv2") > Set colAdapters = objWMIService.ExecQuery _ > ("Select * from Win32_NetworkAdapterConfiguration Where IPEnabled = > True") > For Each objAdapter in colAdapters > Wscript.Echo objAdapter.DNSHostName & "." & objAdapter.DNSDomain > Next > ======= > 3. You'd better replace "clientComputerName" with the clinet name > 4. Double click getNetBIOS.vbs, you would get a pop up dialog > 5. You could launch it from SQL Server by xp_cmdshell > 'Disk:\Patch\getNetBIOS.vbs' in Query Analyzer > > Also, you could have a look at the usage of DOS command: NBTSTAT > > Anyway, I understand this method seems complicated and it has many > limitations. But it's the only way could be provided now. You could have a > look on the following documents, which will show you how to get NetBIOS > through API > > HOW TO: Obtain the NetBIOS and DNS Computer Names by Using Visual C# > http://support.microsoft.com/?id=303902 > > Thank you for your patience and cooperation. If you have any questions or > concerns, don't hesitate to let me know. We are here to be of assistance! > Sincerely yours, > > Michael Cheng > Microsoft Online Support > *********************************************************** > Get Secure! - www.microsoft.com/security > This posting is provided "as is" with no warranties and confers no rights. > Please reply to newsgroups only, many thanks. >
- Next message: Michael Tissington: "Returning Somthing unique about the machine"
- Previous message: Raymond D'Anjou \(raydan\): "Re: Encryption"
- In reply to: Michael Cheng [MSFT]: "Re: Domain Name"
- Next in thread: Michael Cheng [MSFT]: "Re: Domain Name"
- Reply: Michael Cheng [MSFT]: "Re: Domain Name"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|