Viewing 15 posts - 4,441 through 4,455 (of 10,143 total)
Bala' (6/30/2013)
I have an question ,is there any alternative way to get all child in self referencing...
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
July 1, 2013 at 1:16 am
SQLServeruser2304 (6/28/2013)
1. I have 2 input parameters i.e., FromDate...
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
July 1, 2013 at 1:10 am
An index on column msisdn of table vmd_blulm would help, though probably not as much as the plan suggests. I'd do this first because it's likely skewing the relative costs.
The...
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
June 28, 2013 at 7:59 am
-- Gather all of the update info into a skinny temp table
-- then you're done with VoiceData_History.
-- Add a column containing a suitable batch number
-- used to split your data...
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
June 28, 2013 at 6:16 am
Bala' (6/28/2013)
CREATE TABLE #TestTable ([Index] int,[StartNumber] int,[Endnumber] int)
INSERT INTO #TestTable
SELECT 1,1000,1002 UNION ALL
SELECT 2,1550,1555
;WITH TableCte
AS
(
SELECT [Index],[StartNumber] ,[Endnumber] FROM #TestTable
UNION ALL
SELECT [Index],[StartNumber]+1 ,[Endnumber] 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
June 28, 2013 at 4:15 am
There's plenty of scope for improvement - mostly maintainability, but performance too. Compare the original with this (without sample data to test against, it's untested), which is about halfway to...
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
June 28, 2013 at 2:18 am
Lynn Pettis (6/27/2013)
It is actually happening! I am getting much more anxious!
I will probably be dark for about 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
June 28, 2013 at 12:58 am
Or NOT EXISTS. Both compare columns individually rather than concatenating them together which can give rise to false matches.
WHERE NOT EXISTS (
SELECT 1 FROM DSD
WHERE DSD.modify_by = smf6.RespID 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
June 27, 2013 at 9:01 am
Easily tested:
/*
Use a tally table as a row source
DROP TABLE #MyTable
SELECT
col1 = ABS(CHECKSUM(newid()))%32,
col2 = (10000-n)%32,
col3 = n,
col4 = newid()
INTO #MyTable
FROM InlineTally (1000000)
*/
SET STATISTICS IO ON
DBCC DROPCLEANBUFFERS
--...
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
June 27, 2013 at 8:30 am
Why read the table twice?
SELECT
sumyy = sum(yy),
xx = ???('summary line') -- where ??? is an aggregate function
FROM tablea
CROSS APPLY (
SELECT SurrogateGroup = CASE
WHEN somedate_column < @startdate_parameter THEN...
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
June 27, 2013 at 7:48 am
Post the actual execution plan as a .sqlplan attachment.
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
June 27, 2013 at 7:01 am
amardesai89 (6/27/2013)
it runs in 2 hours on server with 8 processors.
and it runs in same time on server with...
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
June 27, 2013 at 6:56 am
GilaMonster (6/27/2013)
Apologies if any arrogance is showing through this morning.
Can't see any arrogance showing through from here, commendable considering the unruliness of the kids in your classroom today.
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
June 27, 2013 at 5:44 am
paul.knibbs (6/27/2013)
Is the "Compute Scalar" part the bit that is ISNULL?
Right-click on the Compute Scalar operator to raise the properties sheet.
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
June 27, 2013 at 3:09 am
paul.knibbs (6/27/2013)
Is ISNULL such an expensive operation, then? (Genuinely curious, never actually sat down and analysed it)...
It's not expensive, but it's not free either. Have a look at the actual...
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
June 27, 2013 at 2:31 am
Viewing 15 posts - 4,441 through 4,455 (of 10,143 total)