Displaying 1 result from an estimated 1 matches for "join_table_seq".
2005 Dec 02
1
Bug with Postgres and/or HABTM?
...tablea(id),
tableb_id integer references tableb(id),
other_attributes...
When Rails writes to join_table, I''d expect it to do something like:
INSERT INTO join_table (tablea_id, tableb_id) values (123,456)
or maybe
INSERT INTO join_table (id, tablea_id, tableb_id) values
(nextval(''join_table_seq''), 123, 456)
Instead, it''s doing something like
INSERT INTO join_table (id, tablea_id, tableb_id) values (123, 123, 456)
with the result that id isn''t being allowed to default to it''s correct
serial value, but is instead having the value of tablea_id written to...