Viewing 15 posts - 31 through 45 (of 78 total)
I've tried recreating your problem on my laptop but with not much success. The only thing I can think is that maybe the table Audit_Trail_Transaction is locked.
A couple of...
October 5, 2010 at 4:41 pm
Just spotted one possible improvement
this sql
SELECT @Field_Position = 0;
WHILE ( @Field_Position < (SELECT MAX(ORDINAL_POSITION) FROM INFORMATION_SCHEMA.COLUMNS with (nolock) WHERE TABLE_NAME = @Table_Name) )
could be changed to
SELECT @Field_Position = 0;
SELECT @Total_Number_Of_Fields...
October 4, 2010 at 3:21 pm
Although your code is nice and generic and can be used by multiple tables with different columns, I think this is also the cause of your issues.
If I'm reading...
October 4, 2010 at 3:18 pm
the Go on this line
ALTER TABLE MyTable DROP CONSTRAINT PK_MyIdGO
needs to be on the following line
ALTER TABLE MyTable DROP CONSTRAINT PK_MyId
GO
September 10, 2010 at 5:55 am
I would also check your disk performance. I've seen two cases recently of very bad performance due to the virtual servers being connected to an overused/failing shared storage.
regards
David
July 27, 2010 at 5:13 pm
Here is one reason why I think select * can be bad.
Lets say that you have two Tables as below which can be joined on ID = ID2
create table Table1...
November 5, 2009 at 12:15 pm
Try to remove the cursor and do the insert within a single operation. Something along the lines of
with existing as
(
select CIFNo ,FacilityType
,max(convert(numeric, SeqNo)) as CurrSeqNo...
October 13, 2009 at 1:22 am
It's useful if you want to know which tables contain data, or contain a lot of rows. I've used the method in the past after a customer had...
September 2, 2009 at 7:24 am
Does using ILSS.SHIPMENT_ID like ABL.[ShipTranNo] + '%' make any difference?
David
August 3, 2009 at 10:14 am
Would it be possible for you to post the queries and the execution plans?
July 14, 2009 at 4:55 pm
thank you for your replies and article links - I will take a look.
Regards
David
July 7, 2009 at 1:46 am
Do you need to a select *? Fewer columns might result in a different index being used.
I guess that running the query directly on the server would remove...
July 6, 2009 at 5:02 pm
the method we use is to store the results of the initial search (limited to 500 rows) in a generic search results table. (Normally just the p.k. ) ...
June 28, 2009 at 2:26 pm
My first step would be to run your query bit by bit to determine which bit(s) are taking too much time.
David
June 22, 2009 at 5:26 pm
Viewing 15 posts - 31 through 45 (of 78 total)