Don't know why that is happening but is there any particular reason why you
have a PK constraint on a temporary table? Have you tried using just a
Andrew J. Kelly
SQL Server MVP
"Uri Dimant" <uridiscar.co.il> wrote in message
> I need someone will shed light on this strange behaviour of temp. table
> SQL 7.0 (sp2) on NT4.0
> I try to create #tem. table with follow syntax.
> CREATE TABLE #Items1 (
> Id int INT NOT NULL ,
> ItemId int NOT NULL ,
> CONSTRAINT PK_Items1 PRIMARY KEY NONCLUSTERED
> A process runs a lot of time and I canceled it
> When I remove CONSTRAINT PK_Items1 PRIMARY KEY NONCLUSTERED
> It runs 0 sec
> PS. I have noticed that It does not happen always I mean sometimes the> DDL works fine.There are a long periods in a day that I need just remove
> constraint creation in order to allow user to continue to work.
> I looked at temp DATABASE ,so it is not full.
> Than you for your help.