Viewing 15 posts - 5,386 through 5,400 (of 10,143 total)
Jeff Moden (10/29/2012)
Eugene Elutin (10/29/2012)
Jeff Moden (10/27/2012)
I wonder how many 3 and 4 letter swear words such a proccess will actually spell out...
Actually it depends how you take it, at...
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 29, 2012 at 6:37 am
That looks fine to me. Ensure statistics are up to date for indexes on Tab2, and check for an index seek in the CI of Tab2 when you insert a...
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 29, 2012 at 6:27 am
ioani (10/29/2012)
I have a stored procedure that selects some data from...
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 29, 2012 at 5:33 am
twoeyed (10/26/2012)
I have managed to reduce the execution to around 6 minutes through the ideas proposed, which...
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 26, 2012 at 7:09 am
Comment out the filter you aren't sure about:
SELECT Db.dbase.name, Db.dbase.ID_Num, Db.dbase.ID_Type, Db.dbase.GroupName, Db.dbase.Region ...
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 26, 2012 at 6:54 am
ksr39 (10/23/2012)
I need a small help in creating non cluster index on a table as we were facing a performance issue. The issue was in one of our production...
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 24, 2012 at 7:23 am
EamonSQL (10/24/2012)
Wrap in brackets giving you a derived table.
Run a delete command against the table and...
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 24, 2012 at 6:49 am
Jeff's nailed it:
-- If *this* query returns any rows
SELECT 1
from Interface a
INNER JOIN AnotherDb.dbo.Trans b
ON (convert(varchar, a.TICKET_NUM) = b.TICKET_NUM and a.TXN_DT = b.TXN_DT)
where a.P_STATUS <> 'R'
-- and b.TICKET_NUM...
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 24, 2012 at 5:54 am
Jeff Moden (10/23/2012)
ChrisM@Work (10/23/2012)
Yes - cast both sides as DATEI don't believe so, Chris... no chance of getting an index seek that way.
That's what I thought too until recently.
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 24, 2012 at 2:36 am
Jeff Moden (10/23/2012)
jerome.morris (10/23/2012)
It has a time stamp also and the cast gave me the errorOperand type clash: date is incompatible with int
Wait a minute now... are you saying that...
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 24, 2012 at 2:34 am
Oops...
CAST(GETDATE() -1 AS DATE)
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 23, 2012 at 7:57 am
jerome.morris (10/23/2012)
SELECT *from SLADB.dbo.DocketTBwhere Docket_EngFinish >=dateadd(d,datediff(d,0, getdate()),-1) AND Docket_EngFinish<dateadd(d,datediff(d,0, getdate()),0)
This works, is there a better way ?
Thanks again Chris 🙂
Yes - cast both sides as DATE
where CAST(Docket_EngFinish AS DATE)...
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 23, 2012 at 7:47 am
Try casting both sides of the comparison as date:
WHERE CAST(Docket_Date AS DATE) = CAST(GETDATE() AS DATE) - 1
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 23, 2012 at 7:23 am
o1548324 (10/13/2012)
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 13, 2012 at 3:21 pm
-- A numeric column will sort numerically.
-- This column is character and will sort alphabetically
-- so you have to work around it. Here's one way.
;with cte as
(
select '1' as...
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
October 13, 2012 at 2:20 am
Viewing 15 posts - 5,386 through 5,400 (of 10,143 total)