Referential Integrity

Post Reply
DrazenZ

Referential Integrity

Post by DrazenZ »

I would like to have one more feature in PHPMaker, extremely usefull: to have control on database referential integrity from Application level, which means - from PHPMaker.

Of course there should be DB Integrity Constraints defined at Database level, in database. But, we can suppose that many of PHPMaker-Users don't know how to handle full DB administration. And this is the reason why PHPMaker (succesfully) handles many other controls (default, required, null)... From PHPMaker it should be so easy and so powerfull!

Here is my example for Data Integrity control on "DELETE" for Master record - PHPMaker User should simply choose from options like:

  • RESTICT deletion (no deletion of Master record if detail record(s) exist)
  • NULLIFY all detail records (and delete Master record)
  • CASCADE delete (or update) all detail records
  • ORPHAN (delete only Master record, leave all Detail records - this is what we have now in PHPMaker ba default)

Thank You in advance. Regards to all.


DrazenZ
User
Posts: 4

Post by DrazenZ »

Today I upgraded to v10. First checked news about Referential integrity. But, not as expected to be. Why?

Please understand that key part is DELETE operation on Master table: PHPMaker should have option to prevent deletion of Master record if Detail record(s) exist.
Please add this functionality. Suggestion: checked "Ref. Integrity" and unchecked "Cascade Delete" should be "Prevent Master record deletion if Detail record exist".


Post Reply