Viewing 15 posts - 406 through 420 (of 486 total)
Robert,
Another good day, I learned something new (and useful).
Thanks!!
P
February 21, 2007 at 8:28 am
Multiple statements in IF / ELSE need to be wrapped in BEGIN...END
February 20, 2007 at 9:41 am
How many users? How educated, as in knowledge of SQL and DBs, are your users? How big is the DB? (Think about it: forget one join clause, and the query...
February 19, 2007 at 7:49 am
Couldn't you then run into the problem of 2 trans beginning at the same time, each getting the same new id number?
February 16, 2007 at 12:51 pm
I just want to know how the app knows which of the two tables to insert.
February 16, 2007 at 6:36 am
How about 1 parent table A with identity, 2 child tables with foreign key and check constraints: table B, all the ids must be divisible by 2 with...
February 15, 2007 at 7:48 am
Here's the correct version (single column in select, ordering not by ordinal position - is that still to be deprecated?)
SELECTcVal
FROM #tmp_holding
ORDER BY CONVERT(INTEGER, STUFF(cVal, 1, PATINDEX('%[0-9]%', cVal) -1, '')), cVal
P
February 14, 2007 at 10:06 am
Try this:
SELECTcVal, CONVERT(INTEGER, STUFF(cVal, 1, PATINDEX('%[0-9]%', cVal) -1, ''))
FROM #tmp_holding
ORDER BY 2, 1
HTH,
P
February 14, 2007 at 10:00 am
Jeff,
VERY COOL!!!!
Never seen that UPDATE...SET construct before.
Not so fast here, tho, took 1m11s.
Thanks,
Paul
February 14, 2007 at 9:47 am
You say this is called from an update trigger, and then give an example involving one 1000 row insert (or 1000 single row inserts). Either way, unless the trigger is...
January 30, 2007 at 9:58 am
Save all your changes in a script file, then cursor through your DBs calling OSQL using xp_cmdshell.
January 25, 2007 at 7:21 am
Michael,
You're too funny!!! You say we're not here to preach, yet you're preaching at me!!!!
I just read your solution to the original question: update syscolumns????? IMHO, that's preaching suicide....
January 3, 2007 at 6:41 am
Michael,
In that case, it's not the ordinal position that breaks things, it's the poor code.
January 2, 2007 at 7:03 am
The ordinal position cannot matter. If you want to see columns in a specific order, select them in that order.
December 27, 2006 at 8:55 am
Hmmn, I put the greater-than / less-than brackets in last post, they were stripped out....
WHERE CHARINDEX(The_Text, TextCol) = 1
December 27, 2006 at 8:24 am
Viewing 15 posts - 406 through 420 (of 486 total)