Viewing 15 posts - 48,946 through 48,960 (of 59,093 total)
My first program was plugging wires into a "program board" for unit record equipment way back when there really were things like bit-buckets. Heh... might be dating myself there,...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 11:11 pm
Uh huh... that's why I wanted to see the commands. And, I'd like to see the DDL for the source and destination tables, as well.
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 11:09 pm
Jack Corbett (8/4/2008)
[font="Courier New"]sp_msforeachdb @command1 = 'Select table_schema, table_name, column_name, data_type from INFORMATION_SCHEMA.COLUMNS'[/font]
Here's an article about...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 9:56 pm
Heh... I just can't bring myself to use something that has a cursor in it like sp_msforeachdb does in the presence of VARCHAR(MAX)... 😛
--===== Code to return all table names...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 9:46 pm
I'll just bet a plugged nickel that there isn't an IDENTITY column in the table...
CREATE TABLE #MyHead (RowNum INT, Something VARCHAR(20))
INSERT INTO #MyHead (Something)
VALUES ('Test row')
SELECT...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 8:42 pm
Heh... I just saw this code posted on our very own forums as part of some dynamic SQL... link withheld to protect the guilty... 😉
,CASE schedule.[letter_box_yn] WHEN ''Y'' THEN...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 8:35 pm
n.yarramreddy (8/4/2008)
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 8:10 pm
Very nicely done, Andy... great walkthrough on what to look for and when it takes affect.
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 8:07 pm
You bet. Thank you for the feedback.
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 7:42 pm
Carla Hepker (8/4/2008)
I assume each debit and credit is associated with a user identifier and has a post date time stamp. If that is the case, it seems to...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 7:40 pm
Understood, but not exactly what I meant... I meant what they do behind the scenes to generate the running total... must be a "machine language" cursor of sorts to get...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 7:36 pm
Actually, Gus' answer is the best answer... "It depends". This is the kind of thing that you need to test.
Gus, good point about the net gain on things like...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 7:33 pm
GSquared (8/4/2008)
I just ran this test:
set statistics time on
go
declare @A char(1)
select @A = left(col4, 1)
from dbo.sometable
select @A = substring(col4, 1, 1)
from dbo.sometable
go 100
Execution time was identical for both commands.
Ah, thanks...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 6:27 pm
dbaker (8/4/2008)
simply that either we should either encourage usage of undocumented features [with due warnings] or not [like pregnancy, there's no middle ground]
Heh... it's not the undocumented features we should...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 6:04 pm
CrazyMan (8/4/2008)
Its supposed to take only a few seconds, since the table is continusly accessed by applicaitons, this is taking me 3 minutes to delete on a Quite time,...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 4, 2008 at 6:00 pm
Viewing 15 posts - 48,946 through 48,960 (of 59,093 total)