Hi All,
Thanks for the suggestions.
I managed to fix this by running CASE on the column. I also fix the %s to
avoid SQLi as per discussed in the documentation of psycopg2.
My apologies for consuming your time, it's my first time to work with DB
and DB migration.
Thanks,
J
On Mon, May 7, 2018 a
On 05/07/2018 12:28 AM, tango ward wrote:
I think I've found the culprit of the problem.
I have a field which is varchar from the source DB while on the
destination DB its integer.
Reading the documentation:
http://www.postgresqltutorial.com/postgresql-cast/ but it gives me error
`psycopg2.
On Mon, May 7, 2018 at 6:35 AM, Adrian Klaver
wrote:
>
>> Not sure but I'm thinking you at least need to add single
>> quotes around the %s symbols. That doesn't really explain
>> the integer input error though I'm not familiar with the
>> exact fe
On 05/06/2018 11:05 PM, tango ward wrote:
Yes, my apologies.
May I also ask if there's a limitation for the number of timestamp with
timezone fields in a table?
On Mon, May 7, 2018 at 1:37 PM, David G. Johnston
mailto:david.g.johns...@gmail.com>> wrote:
Please keep replies on-list, don
On Mon, May 7, 2018 at 12:28 AM, tango ward wrote:
> I think I've found the culprit of the problem.
>
> I have a field which is varchar from the source DB while on the
> destination DB its integer.
>
> Reading the documentation: http://www.postgresqltutorial.
> com/postgresql-cast/ but it gives m
I think I've found the culprit of the problem.
I have a field which is varchar from the source DB while on the destination
DB its integer.
Reading the documentation:
http://www.postgresqltutorial.com/postgresql-cast/ but it gives me error
`psycopg2.DataError: invalid input syntax for integer: ""`
On Sunday, May 6, 2018, tango ward wrote:
> Yes, my apologies.
>
> May I also ask if there's a limitation for the number of timestamp with
> timezone fields in a table?
>
Not one that is likely to matter in practice. There's a page discussing
limitations on the website/docs somewhere if you wis
Yes, my apologies.
May I also ask if there's a limitation for the number of timestamp with
timezone fields in a table?
On Mon, May 7, 2018 at 1:37 PM, David G. Johnston <
david.g.johns...@gmail.com> wrote:
> Please keep replies on-list, don't top-post, and double-check that the
> database table
On Sunday, May 6, 2018, tango ward wrote:
> cur_p.execute("""
>
> INSERT INTO a_recipient (created, mod, agreed, address,
> honor,)
> VALUES (%s, %s)""", (current_timestamp, current_timestamp,
> current_timestamp, '', ''))
>
>
That code doesn't even run (extra co