I have some servers in Europe and some in Asia.
I would like to be able to work out where the current server is by querying ... something.
Is there some global variable I can query or sp_xxx I can execute to find out the locale of the server?
-
I'd go with a parameter in a table.
There can be multiple solutions to the problem, though, and they may or may not work depending on a number of factors. For example, is there any difference in the database server or operating system configuration which could tell one location from the other?
From Romulo A. Ceccon -
sp_helpsortWill show you the sort order and character set of the system
From Matt Rogish -
If the dataserver is properly configured for XP calls, you can execute
xp_cmdshell 'domainname'which will allow you to get the output of the OS 'domainname' command. You can then parse that to determine your locale.
0 comments:
Post a Comment