All Forums Database
TrippKnightly 1 post Joined 12/10
08 Dec 2010
Database "aliasing" -possible

Let's suppose I have database1 & database2. I want to collapse database1 into database2, but I'd like to have legacy code that references database1 still work while we work through the migration.

Doable? Thoughts? Other ways to address?

I may need to provide more info but this seems like a pretty common & general use case so maybe not.

Jimm 298 posts Joined 09/07
08 Dec 2010

There is no "alias" feature within the database, but you can use Unix/ mainframe/ Linux/ Windows scripting to use an alias in scrpts and expend them by shell or JCL features. Make sure you do that when setting up your scripts for database2.
You can also move all your data from database1 to database2 and then set up very simple views in database1 of all the tables in database2 - with the same tablename. Make sure your view are just "select all from database2.tablename" so that they are usable by loads/ updates.

You must sign in to leave a comment.