We have a simple process of archving tables before updates are done here by dev.
We historically had dba's all do it different ways - so now we have a bunch of tables in databases that have different backup names that need to be deleted - dropped from the database.
name types include
Can anyone write me a script that can pick up the tables and print them as results
And then provide a drop statement using print too perhaps that can be executed separately after checking the results found ...
So print tables to be dropped
generate drop statement of table names ready to be executed once checked
The script can have the table names as variables that we can define before running
as i mentioned each database may have slightly different backup names for the archived tables.
Id like the sql ready to work please...
Needs to work for 2005 and 2008 and if possible 2k but 2k not important as much so not a worry if not possible.