Automatic/Scheduled Arvice & Purge?

  • Hiya,

    I am new to the world of SQL in the long sense of the word. I was wondering if there is the functionality of a way of creating a script or automation that archives the current database and transaction logs, then purge the entire database so only the table structure remains, then carry on as normal? It's for data retention purposes mainly and will hardly ever be looked at except in extreme cases, I expect this to happen once a year?

  • Given that it's executed once a year and since you're erasing the whole database, for security I wouldn't use an scheduled task, I'd just prepare an script and run it manually, making sure that I have a good and usable backup before purging

  • If you want to end up with empty tables, it might be simpler & faster to script your existing database objects, rename your current database, and create them as new, instead of purging all the data from the database.

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

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