Unanswered: Need script that can shrink copy of DB to fit on a notebook
I need a script that will take a 40GB 300+ table database and shrink it to the 1st 1000 rows in each table and delete security tables like tblchargecard. Want to get size to about 1gb to fit on a notebook for development. Any suggestions would be appreciated.
Creative, but I think that will crash if you have relational integrity established, and especially if you are using cascading deletes.
If your database does have cascading deletes, (as it should) then just delete everything but, say, every 10th record, out of the highest level tables in the schema. (You can use something like WHERE Right(PrimaryKey, 1) <> 0 if you have numeric keys, for instance.) Do this in a copy of the database, of course!
As far as "delete security tables like tblchargecard", you'll have to specify those in your script.
If it's not practically useful, then it's practically useless.