Hello,
I maintain two database one is in Postgres and second one Oracle.
In order to synchronize them I export data from Postgres as a SQL script and insert into Oracle.
My problem is that export into SQL from Postgres does not translate into a correct insert statement.
here is the example:
Postgres export:
INSERT INTO “TMSCENTRAL”.“stc_events”(“id_track”,“si_station_num”,“ev_notes”,“ev_year”,“dir_id”,“con_id”,“ev_ins_date”,“ev_rem_date”,“ev_receive_date”,“stype_id”) VALUES (5035,‘11s179r’,’’,1/1/2012,1,24,1/24/2012,1/26/2012,4/23/2012,6);
Correct Insert statement:
INSERT INTO “TMSCENTRAL”.“stc_events”
(“id_track”, “si_station_num”, “ev_notes”, “ev_year”, “dir_id”, “con_id”, “ev_ins_date”, “ev_rem_date”, “ev_receive_date”, “stype_id”)
VALUES (5035, ‘11s179r’, ‘’, TO_DATE(‘01-01-2012’,‘DD-MM-YYYY’), 1, 24, TO_DATE(‘24-01-2012’,‘DD-MM-YYYY’), TO_DATE(‘26-01-2012’,‘DD-MM-YYYY’), TO_DATE(‘23-04-2012’,‘DD-MM-YYYY’), 6);
The problems are created by dates.
Would be possible to address the problem in the future ?
I do realize that Postgres database is not your priority.
Regards,
Chris