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

Home » RADICORE » How To » LIST2 Pattern Problem
Re: LINK2 Pattern Problem [message #2127 is a reply to message #2120] Thu, 18 June 2009 09:40 Go to previous messageGo to previous message
ajwid01 is currently offline  ajwid01
Messages: 26
Registered: June 2009
Location: UK
Junior Member
Hmm,

Now I seem to be encountering a new problem.

The LIST2 works fine, having successfully inserted the additional navigation button into the LIST1 form for the parent record(s).

However, the associated child records are not being correctly selected. Every entry from the child table is being returned into the child frame.

Now, initially I thought this would be due to the requirement to ammend the $where string, as the parent PK field is named differently from the child PK field.

I went through the process of trying to trap this, with the use of the recommended additional class function under "Associations" documentation (from an earlier thread).

This still didn't seem to work.

I looked at making the PK/FK field names match, but this wouldn't work either, and I started to run into some 'ambiguous' column errors on SQL selects, so reverted back to different names again.

I have now switched on the SQL Logging for the form, and the output is this:

ALTER SESSION SET CURRENT_SCHEMA = "WAREHOUSE"
SELECT count(*) FROM olap_delivery_data3 WHERE olap_delivery_data3.seq_number='138376'  =>Count=1
select * from ( select a.*, rownum as rnum from ( SELECT olap_delivery_data3.* FROM olap_delivery_data3 WHERE olap_delivery_data3.seq_number='138376'    ) a where rownum <= 1 ) where rnum >= 1=>Count=1
ALTER SESSION SET CURRENT_SCHEMA = "WAREHOUSE"
ALTER SESSION SET CURRENT_SCHEMA = "WAREHOUSE"
SELECT count(*) FROM olap_delivery_notes3 LEFT JOIN olap_delivery_data3 ON (olap_delivery_data3.seq_number=olap_delivery_notes3.delivery_data_seq)   =>Count=2076
select * from ( select a.*, rownum as rnum from ( SELECT olap_delivery_notes3.*, olap_delivery_data3.seq_number FROM olap_delivery_notes3 LEFT JOIN olap_delivery_data3 ON (olap_delivery_data3.seq_number=olap_delivery_notes3.delivery_data_seq)     ) a where rownum <= 25 ) where rnum >= 1=>Count=2076
ALTER SESSION SET CURRENT_SCHEMA = "MENU"
SELECT role_id,global_access FROM mnu_role WHERE role_id='GLOBAL'   ORDER BY role_id  =>Count=1
ALTER SESSION SET CURRENT_SCHEMA = "MENU"
SELECT x.task_id, x.script_id, x.pattern_id, mnu_nav_button.button_text, mnu_nav_button.context_preselect FROM mnu_nav_button LEFT JOIN mnu_task ON (mnu_task.task_id = mnu_nav_button.task_id_snr) LEFT JOIN mnu_task x ON (x.task_id = mnu_nav_button.task_id_jnr)  WHERE mnu_task.task_id='mops_olap_delivery_notes3(list2)' AND (x.is_disabled='N')   ORDER BY mnu_nav_button.sort_seq  =>Count=6


I understand that a where clause should be passed through to the child query from the associated parent record, but there doesn't seem to be any 'where' clause parameter being set.

Do I have to configure this somewhere else?

T.
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Question about the session page stack
Next Topic: AUTO_INCREMENT PK Column for Oracle Table
Goto Forum:
  


Current Time: Sat May 11 12:09:26 EDT 2024

Total time taken to generate the page: 0.01290 seconds