Warning on adding FK from int4 to serial

PostgreSQL - related issues
Post Reply
eduard.sadykov
Posts: 16
Joined: Thu Dec 15, 2011 11:34 am
Contact:

Warning on adding FK from int4 to serial

Post by eduard.sadykov » Thu Dec 15, 2011 11:42 am

DbSchema said: "The from and to column(s) have different data type"

Steve.Taylor
Posts: 25
Joined: Thu Dec 15, 2011 12:52 pm

Re: Warning on adding FK from int4 to serial

Post by Steve.Taylor » Fri Dec 16, 2011 3:36 pm

Hello Eduard,

It's only a warning because the data type it's different for each column, usually it's not recommended to do that, dbschema will create the FK, but it will just give a warning that the columns have a different data type.

Best Regards,

Steve

eduard.sadykov
Posts: 16
Joined: Thu Dec 15, 2011 11:34 am
Contact:

Re: Warning on adding FK from int4 to serial

Post by eduard.sadykov » Sat Dec 17, 2011 10:41 am

Hello Steve,

Thank you for all replies.

guggly
Posts: 1
Joined: Tue Feb 17, 2015 10:56 am

Re: Warning on adding FK from int4 to serial

Post by guggly » Tue Feb 17, 2015 10:59 am

SERIAL columns create as SERIAL but with default value, also created sequence for table

Post Reply