Mutually Exclusive Detail Tables

Post Reply
WABez
User
Posts: 199

Mutually Exclusive Detail Tables

Post by WABez »

Assume the following scenario:

One Master Table, with say 5 Detail Tables, but from the 5 Detail Tables I have two mutually exclusive tables (therefore the user will ALWAYS only see 4 Detail Tables [OR "tabs" and options in the drop-down option list])
MasterTbl ->
-> DetailTblOne,
-> DetailTbleTwo OR DetailTblThree (depending an a user selectable option for example; i.e. DetailTblTwo and DetailTblThree are mutually exclusive),
-> DetailTblFour,
-> DetailTblFive

Therefore the user only see 4 Detail Tables at any one time!

Or to make things even more interesting (having more than two mutually exclusive Detail Tables):
MasterTbl ->
-> DetailTblOne OR DetailTbleTwo OR DetailTblThree OR DetailTblFour (depending an a user selectable option for example; i.e. DetailTblOne, DetailTblTwo, DetailTblThree and DetailTblFour are mutually exclusive),
-> DetailTblFive

Therefore the user see only 2 Detail Tables at any one time.

An example would be similar to "sub-typing" in a database, i.e. (the following is merely to illustrate the objective of my request):

Bank Account = Master Table (fields are common for all types of bank accounts)
-> Checking Account = Detail Table (One - detail fields are different to option Two and Three)
-> Credit Card Account = Detail Table (Two - detail fields are different to option One and Three)
-> Savings Account = Detail Table (Three - detail fields are different to option One and Two)
etc.

Hence, based on the type of bank account, the user now only see that particular Detail Table.

This could be included in the Master/Detail setup of the table within PHP Maker, similar to the "Referential Integrity", "Cascade Delete" and "Cascade Update" options.

I "manually edited" the generated pages and include a "switch" statement to achieve the desired result.

This is done server side, controlling the outputted page, and therefore no "fancy stuff" is required client side to hide stuff, and still be able to view the code when viewing the source code.

This would be something great to have in PHPMaker. This is high on my list!

Thank you.


mobhar
User
Posts: 11700

Post by mobhar »

Great suggestion, and should be included in "Master/Detail" setup, indeed. I second for this.


Post Reply