Viewing 15 posts - 3,991 through 4,005 (of 8,416 total)
Sasidhar Pulivarthi (4/9/2010)
Create a tabular function...
Or better still use one of Chris' methods or:
DECLARE @Example
TABLE (
col1 ...
April 9, 2010 at 8:09 am
Erin-489205 (4/9/2010)
That worked! Thank you very much.
Of course it did π π π
April 9, 2010 at 7:49 am
WayneS (4/9/2010)
matt32 (4/9/2010)
April 9, 2010 at 7:47 am
This is quite efficient too:
DECLARE @Example
TABLE (
row_id INTEGER IDENTITY PRIMARY KEY,
...
April 9, 2010 at 7:39 am
CASE
WHEN xv.EMPLID IS NULL
THEN SUBSTRING(j1.DEPTID, 3, 2) -- COLLATE DATABASE_DEFAULT
ELSE xv.PG1 COLLATE DATABASE_DEFAULT
END...
April 9, 2010 at 7:04 am
Trouble Shooter (4/9/2010)
Hi,Use can use this statement to stop occuring of temp table creation/deletion
select * from tempdb.dbo.sysobjects where name=<Table Name>
Irrelevant nonsense.
April 9, 2010 at 6:59 am
rajagopalanseeth (3/29/2010)
I was migrating my datas and some duplicate rows has been inserted.
Create a unique constraint or index to prevent this happening again.
Ignore the advice about SET ROWCOUNT - it...
April 9, 2010 at 6:58 am
shannonjk (4/8/2010)
The only non-normal piece to this query is that I create a temp table that uses the row_number function and it is recursively used within the select statement.
#temp table...
April 9, 2010 at 6:52 am
Niraj-627298 (4/9/2010)
April 9, 2010 at 6:11 am
This is by design. It is documented in the Remarks section here:
April 9, 2010 at 6:07 am
sku370870 (4/9/2010)
The second situation means about half as many rows in the table but the Where clause has two conditions to match.
Surely you can get the best of both worlds?...
April 9, 2010 at 5:46 am
Dave,
With the FLOOR, the Constant Scan produces 182,511 rows, which are then Filtered to 36,500 rows.
Without the FLOOR, the Constant Scan produces 36,500 rows.
This is too complex to analyse in...
April 9, 2010 at 5:14 am
Tom.Thomson (4/9/2010)
I have to disagree. What you are telling me is that the length of the check expression is 5. That is pure nonsense.
The type of the check...
April 9, 2010 at 4:42 am
Dave Ballantyne (4/9/2010)
HmmmRemoving the Ip calculation and just setting it to zero , brings the run time crashing down to 600 - 700 ms..
The in-line version ends up doing rather...
April 9, 2010 at 2:53 am
Viewing 15 posts - 3,991 through 4,005 (of 8,416 total)