Re: psycopg2.DataError: invalid input syntax for integer: "" - Mailing list pgsql-general

From tango ward
Subject Re: psycopg2.DataError: invalid input syntax for integer: ""
Date
Msg-id CAA6wQLLWBRZvnLYLHxhiV9LLfDPDFxCkt1wUZmw4-ZOwSC0nNw@mail.gmail.com
Whole thread Raw
In response to Re: psycopg2.DataError: invalid input syntax for integer: ""  ("David G. Johnston" <david.g.johnston@gmail.com>)
Responses Re: psycopg2.DataError: invalid input syntax for integer: ""  ("David G. Johnston" <david.g.johnston@gmail.com>)
Re: psycopg2.DataError: invalid input syntax for integer: ""  (Adrian Klaver <adrian.klaver@aklaver.com>)
List pgsql-general
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 Mon, May 7, 2018 at 2:39 PM, David G. Johnston <david.g.johnston@gmail.com> wrote:
On Sunday, May 6, 2018, tango ward <tangoward15@gmail.com> 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 wish to find out more.

David J.

pgsql-general by date:

Previous
From: Ken Tanzer
Date:
Subject: Re: CSVQL? CSV SQL? tab-separated table I/O? RENAME COLUMN
Next
From: "a"
Date:
Subject: Is it possible to get username information while writing trigger?