Viewing 15 posts - 5,326 through 5,340 (of 5,685 total)
These are my results with the null rows removed:
Pattern GapStart GapEnd
-------- -------------------- --------------------
PPCI ...
October 8, 2010 at 3:25 pm
This will sound strange but... are you sure you have gaps?
Run this code:
CREATE TABLE #MidPoint
(RowID INT,
Pattern VARCHAR(100),
Startnum BIGINT,
EndNum BIGINT
)
INSERT INTO #Midpoint
select
ROW_NUMBER() OVER (ORDER BY
left(controlnumber, PatIndex('%[0-9]%', controlnumber)-1),
convert(int, SubString(controlnumber, PatIndex('%[0-9]%', controlnumber),...
October 8, 2010 at 3:04 pm
Found them, the sample rows:
2048205PPCI000737005NULL
2048206PPCI000737009NULL
2048207PPCI000999798NULL
2048208PPCI001346238NULL
2048209PPCI001350958NULL
2048210PPCI001462905NULL
2048211PPCI001620877NULL
2048212PPCI001620882NULL
2048213PPCI001620891NULL
2048214PPCI001620899NULL
2048215PPCI001620909NULL
2048216PPCI001620957NULL
2048217PPCI001620962NULL
They appear to be single page docs. Is this expected in the data?
October 8, 2010 at 2:50 pm
craig-404139 (10/8/2010)
CSV file attached.First column = id
Second column = controlnumber
Third column = endno
That worked. Alright, so we're looking at taking two unique values, figuring out the 'fill', and splitting...
October 8, 2010 at 2:46 pm
Alvin Ramard (10/8/2010)
Brandie Tarvin (10/8/2010)
Ray K (10/8/2010)
Gianluca Sartori (10/8/2010)
At last, Mr. Celko gives a polite and useful answer to a poor-worded question.It's nice to see everyone can learn.
I don't know....
October 8, 2010 at 2:25 pm
I had assumed, since 2k5 and 2k don't behave, but figured it was worth the question. I'm sure Wayne and the others will be able to get you a...
October 8, 2010 at 12:19 pm
craig-404139 (10/8/2010)
Updated the zip. Changed the compatibility to 90, added a pk column, and truncated the old large log (sorry i forgot the first time)
It would appear the internal version...
October 8, 2010 at 12:03 pm
craig-404139 (10/8/2010)
Sure. I was also thinking would this be easier if I added a PK to the table? Both of these columns are just data columns in my production system.
Without...
October 8, 2010 at 11:44 am
Mh-397891 (10/8/2010)
Description: The connection type "SMTP" specified for connection manager "SMTP" is not recognized as a valid connection manager type.
Stripped it down to what I think is critical to...
October 8, 2010 at 11:26 am
craig-404139 (10/8/2010)
Craig Farrell (10/8/2010)
October 8, 2010 at 11:20 am
Sorry guys, came down with a case of the plague yesterday, didn't mean to abandon the topic. Was looking through Wayne's code and Craig-4 (we're gonna need to do...
October 8, 2010 at 11:05 am
WayneS (10/6/2010)
Research links, no. But I've seen deadlocks caused by parallelism before myself... so self-research - yes.
Well, in that case, Amit, try a MAXDOP 1 and see if that helps...
October 6, 2010 at 6:34 pm
WayneS (10/6/2010)
craig-404139 (10/6/2010)
(I've got some real nifty, high-speed code (thanks to Jeff!) to quickly identify gaps...
October 6, 2010 at 6:28 pm
Merge command is handy because it's basically used as an 'upsert', an insert/update.
First, you'd do your deletes separate.
The MERGE would then insert and update simultaneously according to your key. ...
October 6, 2010 at 6:21 pm
And for my last trick...
This ran in about 3:15 on my system
-- First, separate the numbers and their prefixes into usable data.
select
TextID,
LEFT( TextID, MAX( N) ) AS Pattern,
CAST(...
October 6, 2010 at 6:17 pm
Viewing 15 posts - 5,326 through 5,340 (of 5,685 total)