September 10, 2008 at 5:51 am
Hi friends,
We have a Database which consists of around 350 tables by default which all are assigned dbo schema.but now as per the security issue the tables has been divided into 5 differents groups depending on the requirement and i also created 5 different for assigning those related tables each schema.
but now the problem is ,how to move tables with dbo schema to the particular assigned schema ,by using alter schema option i can only move one table at a time ,is there any other option so that all the tables at a time can be moved from default dbo schema to particular schema .
thanks:)
September 10, 2008 at 6:21 am
You could generate the script that moves the tables to a different schema (i.e. generate a script full of "ALTER SCHEMA newschema TRANSFER dbo.oneOfteTables" lines)
Ideally you create one migration script that will help you in the future to find out what you have done to the database. Note that the above statement gets rid of all the permissions on the object that is being transferred.
Regards,
Andras
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply