I did and first I changed the data type around as I mention yesterday. Today I removed the exception to test out. Nothing wrong with the exception but I find out the problem is "relation "sq_staging" does not exit, but the sequence does exist from information_schema.sequences/ I
dropped and recreated sequence successful but when I do the simple select nextval('sq_staging');
ERROR: relation "sq_staging" does not exist. I dropped all sequences and make sure they existed before rebuild the function and trigger. The insert is fine now.
Thank you you all.
v/r,
Bach-Nga
No one in this world is pure and perfect. If you avoid people for their mistakes you will be alone. So judge less, love and forgive more.
No one in this world is pure and perfect. If you avoid people for their mistakes you will be alone. So judge less, love and forgive more.
To call him a dog hardly seems to do him justice though in as much as he had four legs, a tail, and barked, I admit he was, to all outward appearances. But to those who knew him well, he was a perfect gentleman (Hermione Gingold)
**Live simply **Love generously **Care deeply **Speak kindly.
*** Genuinely rich *** Faithful talent *** Sharing success
On Tuesday, February 12, 2019 11:31 AM, David G. Johnston <david.g.johnston@xxxxxxxxx> wrote:
On Tue, Feb 12, 2019 at 9:25 AM Pepe TD Vo <pepevo@xxxxxxxxx> wrote:
>
> I just test out to remove " E' " to see it work because in the near future the syntax convert the data insert into Postgres will be without " E' "
>
> I gave exact code converted from Oracle via Ora2pg without changing any. I just worked around to change the data type to see it work unfortunately, it didn't work :( . The insert is working with function but as soon as I put the trigger in, I get an error.
Its possible my diagnosis was incorrect (or incomplete, is it the
exact same error?) but I don't intend to go back and look at the
original email and dive deeper. You have too many moving parts at the
moment and you need to simplify the code involved by removing
components until you don't get an error and then add them back one at
a time until you get an error - then figure out why the last added
piece of code is wrong.
David J.
>
> I just test out to remove " E' " to see it work because in the near future the syntax convert the data insert into Postgres will be without " E' "
>
> I gave exact code converted from Oracle via Ora2pg without changing any. I just worked around to change the data type to see it work unfortunately, it didn't work :( . The insert is working with function but as soon as I put the trigger in, I get an error.
Its possible my diagnosis was incorrect (or incomplete, is it the
exact same error?) but I don't intend to go back and look at the
original email and dive deeper. You have too many moving parts at the
moment and you need to simplify the code involved by removing
components until you don't get an error and then add them back one at
a time until you get an error - then figure out why the last added
piece of code is wrong.
David J.