finding the create date for a table

  • Is anyone aware of a function which will return the create date of a table?

    I actually have a bigger question which relates to the first I am attempting to create an automated procedure to drop tables created between a specific date in a specified database; does anyone have something written which will do this or something simular which I can work with?

  • Mark

    I believe the sysobjects table has a crdate column, or something similar.  But beware - check what happens when you alter a table (for example by adding a column): does crdate change when you do that?

    I don't recommend deleting tables on the fly - why do you need to do this?

    John

  • Hi John,

    I want to do this simply to keep my database cleaned up in an automated way.  You bring up a good point about the danger of deleting something required so some back up may be important for the first little while to confirm the procedure is working correctly. 

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply