List Item Population [message #405956] |
Mon, 01 June 2009 02:33 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
snsiddiqui
Messages: 172 Registered: December 2008
|
Senior Member |
|
|
Dear All
I have two different list items, one contains list of countries and the second one contains cities.
Country list populates in WHEN_NEW_FORM_INSTANCE trigger and city list should be populate according to country but it isn't.
Here is my code, which I add on country list item and the event is WHEN_LIST_CHANGED
declare
rg_name varchar2(40) := 'PRODPT';
rg recordgroup;
rn number;
begin
rg := find_group(rg_name);
if id_null(rg) then
rg := create_group_from_query(rg_name,'select cd_descr, cd_dcode '
||'from comm_dept '
||'where cd_type = '||'P'
||'order by 1');
else
delete_group(rg);
rg := create_group_from_query(rg_name,'select cd_descr, cd_dcode '
||'from comm_dept '
||'where cd_type = '||'P'
||'order by 1');
end if;
rn := populate_group(rg);
populate_list('pdp_cd_dcode',rg);
end;
I am facing this error.
FRM-41072: Cannot create group PRODPT
FRM-41076: Error populating group
|
|
|
Re: List Item Population [message #405967 is a reply to message #405956] |
Mon, 01 June 2009 03:31 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
|
I faced the same difficulty but i have resolved this issue.I am attaching the form which has similar functionality like yours here in my form i am choosing the sub category based on value chosen in category.You can use this.Please let me know after.
|
|
|
Re: List Item Population [message #405979 is a reply to message #405956] |
Mon, 01 June 2009 04:55 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
cookiemonster
Messages: 13963 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
1) Can you please use code tags, it does make it easier to read.
2) you need to embed quotes in the query for thr cd_type.
this:
||'where cd_type = '||'P'
should be this:
||'where cd_type = '||''P''
3) Both those queries are identical, I'm guessing they shouldn't be.
|
|
|
|