Update of migrate script to make sql oracle and mysql friendly