Previous Thread:   Attribute on return value, how ??

1/13/2006 7:50:00 PM    Inside sql?
1) Can you determine if your UDT is actually executing inside SQL (hence not  
  
on a client)?  
  
2)  Is there a faster way to get something like "@@language" then having to  
  
query for it in connection context?  TIA  
  
--  
  
William Stacey [MVP]



1/13/2006 10:21:25 PM    Re: Inside sql?
For #1, check the value of SqlContext.IsAvailable  
  
I don't know anything about #2.  
  
--  
  
Adam Machanic  
  
Pro SQL Server 2005, available now  
  
http://www.apress.com/book/bookDisplay.html?bID=457  
  
--  
  
"William Stacey [MVP]" <william.stacey@gmail.com> wrote in message  
  
news:%23bSD1RKGGHA.2212@TK2MSFTNGP15.phx.gbl...

1/14/2006 11:26:33 AM    Re: Inside sql?
Thanks Kent and Adam.  
  
--  
  
William Stacey [MVP]  
  
"William Stacey [MVP]" <william.stacey@gmail.com> wrote in message  
  
news:%23bSD1RKGGHA.2212@TK2MSFTNGP15.phx.gbl...  
  
not  
  
to

1/14/2006 11:32:27 AM    Re: Inside sql?
I wanted to set the culture inside a Parse() method to reflect what language  
  
is "Set" in the current session for a Date UDT.  Could this be being set  
  
already automatically?  I was assuming I would have to do this manually.  I  
  
will have to do some more poking.  Thanks Kent.  
  
--  
  
William Stacey [MVP]  
  
"Kent Tegels" <ktegels@develop.com> wrote in message  
  
news:b87ad742c2538c7e6feb658ead0@news.microsoft.com...

1/14/2006 11:46:29 AM    Re: Inside sql?
It appears this does not reflect the current status of "@@language".  
  
--  
  
William Stacey [MVP]  
  
"Kent Tegels" <ktegels@develop.com> wrote in message  
  
news:b87ad742c2538c7e6feb658ead0@news.microsoft.com...

1/14/2006 2:50:32 PM    Re: Inside sql?
Hello William Stacey [MVP],  
  
System.Threading.Thread.CurrentThread.CurrentCulture.IetfLanguageTag  
  
Not exactly the same, but should get you what your looking for. I'm just  
  
afraid to ask what that might be... ;)  
  
Thank you,  
  
Kent Tegels  
  
DevelopMentor  
  
http://staff.develop.com/ktegels/