search for: fk_cp_case_manager

Displaying 3 results from an estimated 3 matches for "fk_cp_case_manager".

2006 Apr 02
5
foreign keys and migrations
Hi: I''m looking to get a point clarified which i''m sure is obvious to everyone else but I haven''t been able to find the answer to. i''ve tried searching through the forums and the api pages and haven''t found anything. Is there a way with migrations to set up foregin key relationships? (beyond putting in the relevant foregin_id attributes) Is
2006 Mar 25
1
foreign keys on migration
...9;'ALTER TABLE ONLY clients ADD CONSTRAINT clients_pkey PRIMARY KEY (id)'' execute ''ALTER TABLE ONLY users ADD CONSTRAINT users_pkey PRIMARY KEY (id)'' # set up foreign key restratints for PostgreSQL execute ''ALTER TABLE ONLY clients ADD CONSTRAINT fk_cp_case_manager FOREIGN KEY (case_manager_id) REFERENCES case_managers(id)'' execute ''ALTER TABLE ONLY placements ADD CONSTRAINT fk_cp_client FOREIGN KEY (client_id) REFERENCES clients(id)'' execute ''ALTER TABLE ONLY placements ADD CONSTRAINT fk_cp_facility FOREIGN KEY (fa...
2008 Jun 05
23
unit test question
In development and production, I''ve got postgresql constraints that prevent deleting a CaseManager if there is a Client that belongs to that CaseManager. In unit tests...and obviously in my testing db, those restrictions don''t get added. Is it wrong to test for deleting dependent records in unit tests? Craig --~--~---------~--~----~------------~-------~--~----~ You received