
diff -r f8f8cac057a7 -r b1dc0efd1303 db/db-schema.sql
--- a/db/db-schema.sql	Fri Apr 20 08:26:23 2012 +0200
+++ b/db/db-schema.sql	Fri Apr 20 08:26:24 2012 +0200
@@ -142,7 +142,7 @@
 alter table "address" add constraint "addressFK1" foreign key ("city_id") references "city"("id");
 alter table "city" add constraint "cityFK2" foreign key ("country_id") references "country"("id");
 alter table "company" add constraint "companyFK3" foreign key ("address_id") references "address"("id");
-alter table "company" add constraint "companyFK4" foreign key ("post_adress_id") references "address"("id");
+alter table "company" add constraint "companyFK4" foreign key ("post_adress_id") references "address"("id") on delete set null;
 alter table "bank_account" add constraint "bank_accountFK5" foreign key ("company_id") references "company"("id") on delete cascade;
 -- column group indexes :
 create index "user_deleted_active_idx" on "user" ("deleted","active");




