BOL - Restrictions
You cannot use TRUNCATE TABLE on tables that:
•Are referenced by a FOREIGN KEY constraint. (You can truncate a table that has a foreign key that references itself.)
Do we have any chance to use a table that has a foreign key that references itself?
Take a Staff table, for example.
some of the columns. may include, inter alia:
StaffId INT IDENTITY(1,1) NOT NULL,
SystemLogin CHAR(10) NOT NULL,
ManagerId INT CONSTRAINT FK_STAFF_MANAGER FOREIGN KEY REFERENCES Staff(StaffId)
Space, the final frontier? not any more...
All limits henceforth are self-imposed.“libera tute vulgaris ex”