[GENERAL] Foreign key constraint accepted even when not same data type

2003-09-22 Thread Jean-Christian Imbeault
Is it right for postgres to accept a foreign key constraint when the type of the field is not the same as that of the foreign key? For example: # Create table a (id int primary key); NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'a_pkey' for table 'a' CREATE TABLE # Create tabl

[GENERAL] Foreign key constraint accepted even when not same data type

2003-09-22 Thread Jean-Christian Imbeault
Is it right for postgres to accept a foreign key constraint when the type of the field is not the same as that of the foreign key? For example: # Create table a (id int primary key); NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'a_pkey' for table 'a' CREATE TABLE # Create tabl