Radicore Forum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » RADICORE » RADICORE Installation Issues » Existing data do not show up in LIST2
Re: Existing data do not show up in LIST2 [message #1086 is a reply to message #1085] Wed, 05 September 2007 06:21 Go to previous message
AJM is currently offline  AJM
Messages: 2363
Registered: April 2006
Location: Surrey, UK
Senior Member
The documentation clearly states at http://www.tonymarston.net/php-mysql/data-dictionary.html#$p arent_relations that the information in $this->parent_relations is only used to add JOIN clauses to an SQL statement. It is not used to modify the $where string which is passed from a parent table object to a child table object. So if the primary key of the parent table is "id=1" then that is what is passed to the child object. If the name of the corresponding foreign key on the child table is anything other than "id" then you will have to change it manually using code in the _cm_pre_getData() method.

The reason that this change in column names cannot be done automatically is that the child object does not know the name of the parent table (remember that there can be more than one parent). Even if it did how could that deal with the situation where there is more than one relationship between the same two tables, as with MNU_TRAN -> MNU_MENU and MNU_TRAN -> MNU_NAV_BUTTON?

This topic is discussed in database-design.html#primary.keys and database-design.html#foreign.key.names


 
Read Message icon5.gif
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: 'Build Directory' is not working!
Next Topic: PROBLEM AT LOGIN PAGE
Goto Forum:
  


Current Time: Sun Oct 20 00:49:33 EDT 2024

Total time taken to generate the page: 0.00943 seconds