how to create sql for constraints when migrating from oracle

Moderator: NorbertKrupa

Post Reply
info4km
Newbie
Newbie
Posts: 3
Joined: Fri Oct 16, 2015 4:16 pm

how to create sql for constraints when migrating from oracle

Post by info4km » Mon Oct 19, 2015 7:52 pm

We are migrating from Oracle to Vertica. We have all of the tables created. Is there an easy way to generate generic/vertica compatible DDL/sql alter commands to add the constraints to the new Vertica DB? Maybe from the all_constraints data. Could oracle dbms_metadata.get_ddl be used to generate commands that we can run directly? I thought maybe someone had tackled this before. If there are tools that may be used that would be helpful as well.

Additionally, if there is an easier way to get the schema info from oracle (including these constraints) to do this at once and have the commands be compatible with Vertica, please let me know.

Thank you in advance.

User avatar
JimKnicely
Site Admin
Site Admin
Posts: 1804
Joined: Sat Jan 21, 2012 4:58 am
Contact:

Re: how to create sql for constraints when migrating from oracle

Post by JimKnicely » Tue Oct 20, 2015 1:08 pm

Check this link:

http://www.vertica-forums.com/viewtopic.php?t=840

Hopefully it'll give you a start :)
Jim Knicely

Image

Note: I work for Vertica. My views, opinions, and thoughts expressed here do not represent those of my employer.

info4km
Newbie
Newbie
Posts: 3
Joined: Fri Oct 16, 2015 4:16 pm

Re: how to create sql for constraints when migrating from oracle

Post by info4km » Tue Oct 20, 2015 2:32 pm

I have seen this already, thanks. We already have the tables, and were hoping to create the constraints all at once some how. Maybe we will need to rethink this and use the ddl to try and create the tables with the constraints at the same time.

I did try to use the get_ddl metadata functions to create the constraints only but keep getting an error on some of them. Anyway that is an oracle issue and not a vertica one.

I will keep looking for tools etc. thanks again.

Post Reply

Return to “Vertica Migration”