Viewing 15 posts - 31 through 45 (of 167 total)
If you're running SQL Server 2005 or above you can use this (some shops disable xp_cmdshell):
Select
client_net_address,local_net_address
from sys.dm_exec_connections
where session_id=@@SPId;
Limitation: You only get IP addresses if you're connective via...
August 2, 2011 at 10:51 am
Microsoft says a lot of things about their Command Prompt/DOS emulation environment, some of which is conflicting... From my experience the code presented in my previous post will work under...
March 29, 2011 at 1:46 pm
I agree with Jeff on the xp_CmdShell issue. With proper server security (proxy account) its not an issue.
xp_CmdShell can be very handy when processing data, however, DOS mode or Command...
March 29, 2011 at 11:57 am
Dude, you rock! I totally missed that in BOL... But I'm still not going to take back the MICROSOFT @)(@#$)(*@#$#@$...
December 16, 2009 at 12:19 pm
MICROSOFT @#$(*&@#$(*%&@#$... the saga continues...
One other thing... When you code:
Select (Select 1[Number] for XML Path('root'))
the output result type is character! I recoded, again, to the following:
Select Cast((Select 1[Number] for XML...
December 16, 2009 at 11:19 am
MICROSOFT @(*&#$%)(*@#$...
I've recoded my original sproc with the above change to the XML output SELECT statement and am now able to insert it's output into a table with an XML...
December 16, 2009 at 11:13 am
Just figured this out to some degree. If you code:
if object_id('tempdb.dbo.#tmp') is not null drop table dbo.#tmp;
create table dbo.#tmp(x xml);
insert dbo.#tmp
select 1 [Number] for xml path('root')
it will fail with Msg...
December 16, 2009 at 11:10 am
Thanks Crazy Eights, I too can make your example work in SSMS but when I replace your simple sproc with the one from my shop I get the following error...
December 16, 2009 at 10:59 am
Custom aggregators...
bit-wise aggregation; OR, AND, XOR...
string aggregation; deduped concatenation, longest string, shortest string, longest left/right most match,...
intelligent date/time aggregation
XML aggregation
...
December 11, 2009 at 11:19 am
You can also assign a UniqueIdentifier by casting from a VarBinary data type.
Select Cast(Cast(1 as VarBinary(16)) as UniqueIdentifier)
Play around with the VarBinary size and the integer being cast and see...
November 2, 2009 at 9:21 am
I have been in this business for many years and am constantly exposed to this behavior. I've witnessed it's beginnings and progress to the "art form" status it receives today.
The...
September 21, 2009 at 8:06 am
Wow... you guys are extremely caustic... its a wonder any bother to post here anymore. I made a simple comment regarding how we use a facility. Take it or leave...
September 18, 2009 at 10:28 am
We use extended attributes to track things of interest to us like deprecation and TTL (time to live) on SQL objects...
September 17, 2009 at 3:46 pm
Sparring and competition are my favorite martial arts expressions too!
You can talk about programming all day long (blogging). If you really want to know if you can do it, write...
August 14, 2008 at 8:46 am
Viewing 15 posts - 31 through 45 (of 167 total)