Sub:column "" is of type bigint but expression is of type character varying - Mailing list pgsql-general

From Rama Krishnan
Subject Sub:column "" is of type bigint but expression is of type character varying
Date
Msg-id CAJWX+ENJ-Z6Unwru0PR+WBvi4eJjYJay9GPyeCNvXxSBe5Rkmw@mail.gmail.com
Whole thread Raw
Responses Re: Sub:column "" is of type bigint but expression is of type character varying
Re: Sub:column "" is of type bigint but expression is of type character varying
Re: Sub:column "" is of type bigint but expression is of type character varying
List pgsql-general
Hi All,

I am having table name called tickets


\d tickets

            Column            |            Type             | Collation | Nullable | Default
------------------------------+-----------------------------+-----------+----------+---------
 id                           | bigint                      |                        | not null |
 ticket_purchase_no| bigint                     |                        | not null | 

this below table contains more than 2 years old data
\d tickets_archive 

            Column            |            Type             | Collation | Nullable | Default
------------------------------+-----------------------------+-----------+----------+---------
 id                           | bigint                      |                        | not null |
 ticket_purchase_no| bigint                     |                        | not null | 




i have purged the old data from orginal table when i am restoring the data from archive table into orignal table i am getting the error


insert into tickets select * from tickets_archive;


 column "ticket_purchase_no" is of type bigint but expression is of type character varying
Regards

A.Rama Krishnan

pgsql-general by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: Would it be possible to add functions to tab-completion in psql?
Next
From: "Peter J. Holzer"
Date:
Subject: Re: Can I get the number of results plus the results with a single query?