Link to home
Start Free TrialLog in
Avatar of coldchillin
coldchillin

asked on

Migrating Data - Tables with different structure

What is the easiest/best way to accomplish the following:

During the process of an upgrade we are migrating data, but the table structure is slightly different. For the most part, the new table has additional fields, but it is possible that it is missing fields.

What is the easiest way to get the matching fields carried over?
ASKER CERTIFIED SOLUTION
Avatar of biggstrc
biggstrc

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Avatar of gdemaria
gdemaria
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of coldchillin
coldchillin

ASKER

The User table has a ton of columns. I was hoping to avoid going through and coding for all of them...I guess that's not possible?
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
If mine were only for internal use, I might do it differently - never thought about it. The DB I work with supports our primary product, which is a large MES system. So, when I do updates, after my unit testing, they get tested to death by our QA group before they are shipped to customers with the latest revision of the product.

Obviously, when they get to the customer site, they need to be pretty much foolproof. So each bit of script gets wrapped in a script that verifies that it has not been run once already, then runs the script, then records whether it succeeded. Then the whole thing gets wrapped in one script to synchronize the whole thing. It gets pretty complicated, but the customer's DBAs seem to appreciate it.