Displaying 1 result from an estimated 1 matches for "fk_items_category".
2006 Mar 30
5
Heeelp - no idea what''s going wrong.
...g.save
...
...
end
And the databases:
create table listings (
id int not null auto_increment,
<various text fields>
primary key (id)
);
create table subcategories (
id int not null auto_increment
name varchar(100) not null,
category_id int not null,
constraint fk_items_category foreign key (category_id) references
categories(id),
primary key (id)
);
create table listings_subcategories
(practically a duplicate of categories_listings, which works)
subcategory_id int not null,
listing_id int not null,
constraint fk_cp_subcategory foreign key (subcategory_id) re...