I'm writing sql scripts which I would like to run across platforms (mostly mysql and postgres). The problem I see is I cannot arrive at a common one for auto-increment primary keys which are used as foreign keys. Is there a way to do this ?
table t1 ( column c1 )
table t2 ( column c2 )
c1 is auto increment and c2 is a foreign key referenced on c1.
I tried keeping c1 as SERIAL and c2 as bigint/bigint unsigned/numeric , but no luck.