Dropdown from record group?
I am new to oracle, i need to have dropdown value list from a database, i know LOV, but it does not support dropdown so i need some way from LOV or from Record group.
Please if anybody guide me that how can i make a dropdown linst using LOV or Record Group.
I am using 10g forms.
Kind Regards
Naveed
You can populate list item (if you mean list item) using record group.
Example: you can use create_group_from_query and populate_group built-ins to get the values from database into record group.
Then you can use populate_list to populate list item.
Also, have a look at Oracle Forms help for more information and examples on built-ins.
regards
Srinidhi Rao
Similar Messages
-
URGENT,FRM-41337: Cannot populat the list from record group
Hi all:
Can anyone help me in that problem?
I have a database item in the block as a list item with combo box style and I use this code in WHEN-NEW-RECORD-INSTANCE at the form module level to populate that combo box list:
DECLARE
group_id RECORDGROUP := FIND_GROUP('group');
list_id ITEM := FIND_ITEM('employees.job_id');
x number;
BEGIN
IF NOT ID_NULL (group_id) THEN
DELETE_GROUP (group_id);
END IF;
group_id := CREATE_GROUP_FROM_QUERY ('group','select name,TO_CHAR(id) job from cmn_jobs where job_type_id = 4720 ');
x := POPULATE_GROUP (group_id);
POPULATE_LIST (list_id, group_id);
EXCEPTION
WHEN NO_DATA_FOUND THEN
null;
END;
That code worked very well and without any problem, but when I change the list item from combo box style to poplist style then the forms give that error:
FRM-41337: Cannot populat the list from record group
And an additional null/blanke element appears in the poplist with original element that come from RECORDGROUP.
So can anyone help me to solve that problem please?First, how I can assign a default or initial value DYNAMICALLY to my poplist.Set the default-value to a parameter like :PARAMETER.MYPARAMETER then you can assign the desired default-value to the parameter.
second, if I have popliste say X for example depend on another poplist say Y ,so when I put the code to populate popliste X on WHEN-LIST-CHANGED on popliste Y and make query then the >forms return FRM-40301 Query caused no records to be retrieved ,but when I have a copy for that code in WHEN-LIST-CHANGED and put it in WHEN-NEW-FORM-INSTANCE at the form >module the form work and returns records, so is it any error or exception in what I did.Can't answer that, you should check :SYSTEM.LAST_QUERY to see why the query does not returnany records.
At the last, which better to put the code for popliste in PRE-FORM trigger at the form module or in WHEN-NEW-FORM-INSTANCE at the form module.I would use the PRE-FORM-trigger -
Frm - 41337 - can not populate the list from record group
Hi
I have created a form with 4 combo boxes. And i am trying to populate the 4 combo boxes dynamically.
Here is my table structure.
BUS_FUNCTION VARCHAR2(500),
SEQ NUMBER,
STEP1 VARCHAR2(500),
STEP2 VARCHAR2(500),
STEP3 VARCHAR2(500),
STEP4 VARCHAR2(500),
KEYSTEP VARCHAR2(4000),
OBJ_NAME VARCHAR2(500),
SME VARCHAR2(50)
In the fist combo box i am retriving bus_function and second seq and third step1.
i wrote a trigger when_new_form_instance and i am calling a procedure from the trigger.
here is my procedure code.
PROCEDURE fp_get_list IS
l_sql_text VARCHAR2(2000);
BEGIN
l_sql_text := 'SELECT bus_function,bus_function FROM TABS_BUS_FUNC';
lp_populate_list('BUSFUNC.list22','rgcat2',l_sql_text);
l_sql_text := 'SELECT TO_CHAR(SEQ),TO_CHAR(SEQ) FROM TABS_BUS_FUNC';
lp_populate_list('BUSFUNC.BUS_FUNC','rgcat',l_sql_text);
l_sql_text := 'SELECT step1,step1 FROM TABS_BUS_FUNC';
lp_populate_list('BUSFUNC.list20','rgcat1',l_sql_text);
END;
Now the problem is i can able to get the values fro the first two colums. but the third column values are not populating.
i am getting an error frm - 41337 - can not populate the list from record group.
PLease help me in this.
Thanks in advance,
RajuI got answer
i write a code in when-new-form-instance
declare
v_rg_id RECORDGROUP;
v_return number;
v_query varchar2(2000);
outcome number ;
begin
v_rg_id := CREATE_GROUP_FROM_QUERY('RG_LIST','select Dname,To_char(Deptno) deptno from dept');
v_return := POPULATE_GROUP(v_rg_id);
POPULATE_LIST('emp.deptno', 'RG_LIST');
end;
but remember property of list item must be mapping of others value null and initial value null
if ur problem not solve then tel me email, i ll send u fmb file -
FRM-41337: Cannot populate the list from record group.
My task is to populate the list after a list changed is triggered in another list item. I have 2 list items, report_type ans subgroup_type. When report type is changed, I have to get the value from it and create a select statement for subgroup_type. Here's what I did in the pre form:
PROCEDURE INITIALIZE_LIST IS
BEGIN
for Preparation status
DECLARE
rg_list_id recordgroup;
rg_name varchar2(20) := 'REC_REPORT_TYPE';
ret_code number;
-- the following holds select query from which the lst element are d
-- derived
v_select varchar2(300);
BEGIN
v_select := 'SELECT description, lookup_code FROM tmx.tmx_lookups '||
'WHERE lookup_type = ''RTV_REPORT_TYPE'' AND enabled_flag = ''Y'' '||
'ORDER by 1';
rg_list_id := find_group(rg_name);
if not id_null(rg_list_id) then
delete_group(rg_list_id);
end if;
rg_list_id := create_group_from_query(rg_name, v_select);
ret_code := populate_group(rg_list_id);
populate_list('start.s_report_type', rg_name);
delete_group(rg_list_id);
END;
END;
and in the s_report_type list change event, here's what I do:
BEGIN
DECLARE
rg_list_id recordgroup;
rg_name varchar2(20) := 'REC_SUBGROUP_TYPE';
ret_code number;
v_select varchar2(300);
BEGIN
v_select := 'SELECT description, lookup_code FROM tmx.tmx_lookups '||
'WHERE lookup_type = ''' || :start.s_report_type || ''' AND enabled_flag = ''Y'' '||
'ORDER by 1';
rg_list_id := find_group(rg_name);
if not id_null(rg_list_id) then
delete_group(rg_list_id);
end if;
rg_list_id := create_group_from_query(rg_name, v_select);
ret_code := populate_group(rg_list_id);
populate_list('start.s_subgroup_type', rg_name);
delete_group(rg_list_id);
END;
END;
and the FRM-41337 error is triggered. Please point me out where I missed. Thanks a lot.try to change query with this
'SELECT description, to_char(lookup_code)........and dont delete the group after
Baig
[My Oracle Blog|http://baigsorcl.blogspot.com/] -
FRM-41337: Cannot pop list from record group
If I update a record from a poplist and try to re-populate the list, i get this error. I've read you need to have a default or other values listed, unless it can accept NULL values. Well, it CAN accept NULL values, and required property is set to NO. I'd appreciate your help.
On-line help says:
ADD_LIST_ELEMENT restrictions:
For a base table list with the List Style property set to Poplist or T-list, Form Builder does not allow you to add another values element when the block contains queried or changed records. Doing so causes an error. This situation can occur if you have previously used DELETE_LIST_ELEMENT or CLEAR_LIST to remove the other values element that was specified at design time by the Mapping of Other Values list item property setting.
Note: The block status is QUERY when a block contains queried records. The block status is CHANGED when a block contains records that have been either inserted or updated. -
Understanding the internal operation of creating a record group
Hi gurus,
When record group is created, if the query has a lot of records generated , does the form actually retrieve all the data from database in the record group when get_group_xxx function is called or there is also buffering like we do execute query from a base table block where only a set of data being buffered is retrieved from db.
The concerns is that whether the memory will increase exponentially if the data retrieve from record group is huge.The group is not populated when you create it. However, when you issue the populate_group command, it does indeed retrieve all the records into memory. So it is not a good idea to use a record group if you will retrieve more than a few thousand rows.
-
Hi,
In forms, I am storing some values in a plsql table(like an array). Everytime a value is chosen in the filter, I do a sequential search of the table to retrieve my values. As this is a single table the search is taking a long time.I would like to replace this with multiple run time record groups. My question is whether the storing and retrieval from record groups are in any way faster or slower than retrieval from a table? I dont know the exact row number. So I have to do a sequential read of the record group also. So it will be something like :
for i in 1..10 loop
v := get_group_char_Cell('col name',i);
end loop;
Is this faster than
for i in 1..10 loop
v := tab(i).col;
end loop;
Ps: The record group could be smaller than the table as it will be multiple. Table will be always be one.
Thanks in Advance.Hi ,
I have a filter which has certain values. When the value is chosen, I need to look thru either the table or record group sequentially to get the matched record and apply it. We want to make this process as fast as possible. Hence the question of using plsql table vs record groups vs GLOBAL table. I was given to understand that if the global table is indexed it could be as fast or faster than the plsql table. The advantage in using GLOBAL table might be that I can directly select the value instead of retrieving the entire PLSQL table and compare the values.
EG -
for i in 1..tab.count loop
tab(i).col = val;
end loop
select col into v from GLOBAL_TAB where col1 = val;
So which you think would be faster? Also consider the record groups.
Thanks in Advance. -
How to get query from a record group
HI
do we get the query from which record groupis based on in oracle forms with out checking in to the properties.Hello,
No, you cannot get the initial SELECT order from the Record Group.
Francois -
Record Group and From-Clause Datasource
I need to do several complex queries (read-only) for my form. Original I used From-Clause datasource but, as the requirement changed, there are some limitations. I would rather no do anything dynamically if as all possible because there are over 20 such queries which makes the code difficult to maintain. I wanted to be able to reference block items in the query.
I'm thinking about using Record Group query instead. What are the differences in capability between Record Groups and From-Clause Datasource?
Thanks.
Clayton.Thanks.
That's exactly the problem I have. I don't want to use LOVs so I've been thinking about how to visualize the record group data using data blocks. Perhaps I'll just go with dynamically building the From-Clause.
I've looked into stored procedure based blocks a bit; it was confusing for me. Are the stored procedures stored in the database or are they defined in the form? -
SQL to group the records and apply logic to pick one record from each group
Hi Friends,
I am looking for a query to group the records on certain columns in a table and then from each group I want to pick only one record based on certain rules.
May be having data laid out will make my point more clear to you. Here you go :
CREATE TABLE AD_LIST
FILE_NAME VARCHAR2(50 BYTE),
ACTIVITY_START DATE,
ACTIVITY_END DATE,
DIVISION VARCHAR2(50 BYTE),
ITEM_CODE VARCHAR2(50 BYTE),
MULT NUMBER,
RETAIL NUMBER,
AD_PAGE VARCHAR2(1 BYTE),
FORECAST NUMBER,
MEMO VARCHAR2(50 BYTE)
INSERT INTO AD_LIST VALUES ('FILE_1','01-APR-2010','15-APR-2010','B',1111,5,10,'A',10,'This must be in my result');
INSERT INTO AD_LIST VALUES ('FILE_1','01-APR-2010','15-APR-2010','B',1111,1,1,'B',15,'Must not be in my result');
INSERT INTO AD_LIST VALUES ('FILE_1','01-APR-2010','15-APR-2010','B',1111,6,15,'C',11,'Must not be in my result');
INSERT INTO AD_LIST VALUES ('FILE_1','16-APR-2010','30-APR-2010','N',1111,4,20,'D',40,'Must not be in my result');
INSERT INTO AD_LIST VALUES ('FILE_1','16-APR-2010','30-APR-2010','N',1111,5,15,'E',30,'Must not be in my result');
INSERT INTO AD_LIST VALUES ('FILE_1','16-APR-2010','30-APR-2010','N',1111,1,2,'F',20,'This must be in my result');
CREATE TABLE PAGE_RANK
AD_PAGE VARCHAR2(1 BYTE),
RANK NUMBER
INSERT INTO PAGE_RANK VALUES ('A',1);
INSERT INTO PAGE_RANK VALUES ('B',2);
INSERT INTO PAGE_RANK VALUES ('C',3);
INSERT INTO PAGE_RANK VALUES ('D',4);
INSERT INTO PAGE_RANK VALUES ('E',5);
INSERT INTO PAGE_RANK VALUES ('F',6);
COMMIT;
SELECT * FROM AD_LIST
FILE ACTIVITY ACTIVITY ITEM AD
NAME START END DIV CODE MULT RETAIL PAGE FORECAST MEMO
FILE_1 4/1/2010 4/15/2010 B 1111 5 10 A 10 This must be in my result
FILE_1 4/1/2010 4/15/2010 B 1111 1 1 B 15 Must not be in my result
FILE_1 4/1/2010 4/15/2010 B 1111 6 15 C 11 Must not be in my result
FILE_1 4/16/2010 4/30/2010 N 1111 4 20 D 40 Must not be in my result
FILE_1 4/16/2010 4/30/2010 N 1111 5 15 E 30 Must not be in my result
FILE_1 4/16/2010 4/30/2010 N 1111 1 2 F 20 This must be in my resultNow, from the table AD_LIST I want to group the records based on FILE_NAME, ACTIVITY_START, ACTIVITY_END, DIVISION, ITEM_CODE.
So in my example here we have 2 set of records grouped based on the columns specified.
Also we have one more table, PAGE_RANK, which has a rank corresponding to each ad_page number. Here 1 is higher rank than 2. Hence ad page 'A' takes priority over 'B'. Similarly for all other ad pages.
Now, we need to pick one ad from each group of ads by determining the highest ranked ad page within the group and the value for mult and retail must be replaced with the value that has min(retail/mult). So, using the above data we will have the one having ad page = 'A' and ad page = 'D' as the final results since they have highest ad page rank in their group.
The value for mult and retail values for ad_page 'A' = min (10/5 , 1/1, 15/6) = 1,1(mult,retail).
The value for mult and retail values for ad_page 'D' = min (20/4 , 15/5, 2/1) = 1,2(mult,retail).
Finally I have this query below
SELECT a.file_name,
a.activity_start,
a.activity_end,
a.division,
a.item_code,
FIRST_VALUE (a.mult) OVER (PARTITION BY a.file_name, a.activity_start, a.activity_end, a.division, a.item_code ORDER BY (a.retail /
a.mult))
mult,
FIRST_VALUE (a.retail) OVER (PARTITION BY a.file_name, a.activity_start, a.activity_end, a.division, a.item_code ORDER BY (a.retail /
a.mult))
retail,
FIRST_VALUE (a.ad_page) OVER (PARTITION BY a.file_name, a.activity_start, a.activity_end, a.division, a.item_code ORDER BY (b.RANK))
ad_page,
a.forecast,
a.memo
FROM ad_list a, page_rank b
WHERE a.ad_page = b.ad_pageThis query is giving me all the records but with the values what I wanted in Ad_Page, Mult and Retail columns.
How can I pick only one from each group.
I am getting this FILE ACTIVITY ACTIVITY ITEM AD
NAME START END DIV CODE MULT RETAIL PAGE FORECAST MEMO
FILE_1 4/1/2010 4/15/2010 B 1111 1 1 A 15 Must not be in my result
FILE_1 4/1/2010 4/15/2010 B 1111 1 1 A 10 This must be in my result
FILE_1 4/1/2010 4/15/2010 B 1111 1 1 A 11 Must not be in my result
FILE_1 4/16/2010 4/30/2010 N 1111 1 2 D 20 This must be in my result
FILE_1 4/16/2010 4/30/2010 N 1111 1 2 D 30 Must not be in my result
FILE_1 4/16/2010 4/30/2010 N 1111 1 2 D 40 Must not be in my resultBut I want this FILE ACTIVITY ACTIVITY ITEM AD
NAME START END DIV CODE MULT RETAIL PAGE FORECAST MEMO
FILE_1 4/1/2010 4/15/2010 B 1111 1 1 A 10 This must be in my result
FILE_1 4/16/2010 4/30/2010 N 1111 1 2 D 20 This must be in my resultI have to run this query for thousands of such group combination.
Hope some one can throw some light on this query.
Thanks in advance,
Raj.Frank,
You are marvelous.
That is what I was expecting, but basically I want to display the row with highest page rank which is 'A' and 'D' in this case.
So I have changed my query as below using yours :
WITH mainq AS
(SELECT a.file_name,
a.activity_start,
a.activity_end,
a.division,
a.item_code,
FIRST_VALUE (a.mult) OVER (PARTITION BY a.file_name, a.activity_start, a.activity_end, a.division, a.item_code ORDER BY (a.retail /
a.mult))
mult,
FIRST_VALUE (a.retail) OVER (PARTITION BY a.file_name, a.activity_start, a.activity_end, a.division, a.item_code ORDER BY (a.retail /
a.mult))
retail,
--FIRST_VALUE (a.ad_page) OVER (PARTITION BY a.file_name, a.activity_start, a.activity_end, a.division, a.item_code ORDER BY (b.RANK))
a.ad_page,
a.forecast,
a.memo,
ROW_NUMBER () OVER (PARTITION BY a.file_name, a.activity_start, a.activity_end, a.division, a.item_code ORDER BY b.RANK)
AS r_num
FROM ad_list a, page_rank b
WHERE a.ad_page = b.ad_page)
SELECT *
FROM mainq a
WHERE r_num = 1
FILE ACTIVITY ACTIVITY ITEM AD
NAME START END DIV CODE MULT RETAIL PAGE FORECAST MEMO
FILE_1 4/1/2010 4/15/2010 B 1111 1 1 A 10 This must be in my result
FILE_1 4/16/2010 4/30/2010 N 1111 1 2 D 40 Must not be in my resultMy apologies that I gave you wrong forecast and memo values in my earlier post.
But that is what I wanted and your input greatly helped me to save lot of time by using in one single query.
Earlier I was using cursor to do that and it was not doing any good performance wise.
Thanks to every body for your time and your efforts.
I appreciate it.
Have fun.
~Raj -
How to pass record Group from Forms with DATA_PARAMETER to Reports Server
How to pass record Group from Forms with DATA_PARAMETER to Reports Server using RUN_REPORT_OBJECT?
When we use products on run time we are using data_parameter for passing record Groups to reports via run_product but now we have to use application server and reports server for same reports.
We met with <FRM-41214 Unable to run reports> for passing DATA_PARAMETER to reports server when used RUN_REPORTS_OBJECT.
How can we pass record Group from Forms with DATA_PARAMETER to Reports Server using RUN_REPORT_OBJECT?
Thanks,
ArifHi Mandeep,
Could you please tell me how can i pass data parameter from forms to report through run_product. -
One to Many table join -- concat field per record grouped by id
Post Author: wm5
CA Forum: Formula
Hello,
I am using Crystal Reports XI and have two tables that have a one to many relationship and are joined by an JobID (number).
Below is a sample with relative fields for each table.
job_table: JobID (number), Manager (text), Status (text)
jobaudit_table : JobAuditID (number), JobID (Number), FormID (Number)
There is a one to many relationship with jobaudit_table having multiple records for each JobID in job_table.
I have created a Group Header using the job_table.JobID and suppressed the detail section.
In the group header for each JobID I display the JobID, Manager, Status. I also use the below formula to determine if any records in the jobaudit_table has a record where FormID = 90. If so, I display "Yes". If not, "No".
So my report currently looks like.
JobID Manager Status Audit Performed
1 Manager 1 Closed N
2 Manager 2 Closed Y
Here are the formula's I use to determine if any records in jobaudit_table contains a record where FormID = 90.
@ja90exists
if {jobaudit_table.FormID} = 90 then 1else 0;
if sum({@ja90exists},{job_table.JobID}) = 0 then "No"else "Yes";
Everything so far works fine. What I would like to do now is add a hyperlink to a script to view the job audit when in the above report the "Audit Performed" column is "Yes"
So Report is now:
JobID Manager Status Audit Performed
1 Manager 1 Closed N
2 Manager 2 Closed Y (hyperlink to view audit)
I cannot figure out how to gather the valid JobAuditIDs where FormID = 90 grouped by JobID to be used in the Group Heading section of the report.
Also, it is unlikely, but possible that more than one job_audit record exists with FormID = 90 per JobID. So, my hyperlink could look like http://mysite.com/viewjobaudit.aspx?jobid=[jobaudit_table.JobAuditID],[jobaudit_table.JobAuditID] .
Thanks for any help. And if this post is not clear let me know and I will clarify.
wm5Post Author: bettername
CA Forum: Formula
Although I can't think of a way to get multiple hyperlinks, this should be a start. It (should) hyperlink to the last job/audit in the group that formID of 90. Oh, I assumed that the hyperlink should have been xxxx...jobID,jobAuditID!
I think there may be a way of getting hyperlinks to every "90" record, but that will involve a subreport, so lets try this first...
1 - everything from your group header to the group footer...
2 - add a formula into the group header that says:
whileprintingrecords;
stringvar jobauditID="";
stringvar jobID:=";
3 - Then add a formula to the details section:
whileprintingrecords;
stringvar jobauditID;
stringvar jobID;
if {jobaudit_table.FormID} = 90
then (jobID:=totext({job_table.job_id},0,""); jobauditID:=totext({jobaudit_table.jobaudit_id},0,"")
4 - Finally, on your "Audit Performed" formula, have a conditional hyperlink that says:
whileprintingrecords;
stringvar jobauditID;
stringvar jobID;
if {@audit performed} = "Y" then http://mysite.com/viewjobaudit.aspx?jobid=jobID","+jobauditID -
Dynamically populate a record group on the fly uisng LOV
Hi,
I want to create dynamically populate a record group on the fly uisng LOV.
1. This is how the RG_BANKNAME Record Group object look like
Object : Record Group
Name : RG_BANKNAME
Record Group Query : SELECT NAME, SHORT_NAME FROM C_BANKS
2. I create the Push Button and when user click it will popup the LOV.
DECLARE
rg_id RecordGroup;
errcode NUMBER;
status BOOLEAN;
BEGIN
rg_id := Find_Group('RG_BANKNAME');
IF Id_Null(rg_id) THEN
Message('No such group: ',ACKNOWLEDGE);
RAISE Form_Trigger_Failure;
ELSE
errcode :=POPULATE_GROUP(rg_id);
SET_LOV_PROPERTY('LV_NAME', TITLE, 'My Own LOV');
SET_LOV_PROPERTY('LV_NAME', GROUP_NAME, rg_id);
SET_LOV_COLUMN_PROPERTY('LV_NAME', 1 ,Title, 'NAME');
SET_LOV_COLUMN_PROPERTY('LV_NAME', 1 ,Width, 150);
SET_LOV_COLUMN_PROPERTY('LV_NAME', 2 ,Title, 'SHORT NAME');
SET_LOV_COLUMN_PROPERTY('LV_NAME', 2 ,Width, 100);
status := Show_LOV('LV_NAME',10,20);
IF NOT status THEN
Message('You have not selected a value.');
Bell;
END IF;
END IF;
END;
My question is do I need to create the LOV Object name call 'LV_NAME'? since I don't have this
create on my design times, because I thought it can be done dynamically on the fly.
The problem is compliant that the Lov Id is not valid.
Thanks
David
Edited by: user445990 on May 24, 2011 9:19 PMHello,
You request is not clear. Do you need to display the LOV or not ? In other words, what is the goal of your record group ?
Francois -
How to tell if someone removed you from a group co...
I'm new to skype so I apologize if this is a dumb question! When I go to "participants" it doesn't show I'm there, and the group hasn't been active in 3 days, which is odd since they are usually very active. Does it say you have been removed from the group or anything like that when the admin removes you? How can you tell if someone removes you? Thanks
If your plugin is doing the exporting, just record which collections are in active sources upon export.
PS - I'm not aware of any problems with catalog:getActiveSources(), other than differences in what's returned for the special collections (e.g. all-photos and recent-imports collections) vs. non-special collections.
Of course you can't add photos to smart collections, so if collection is smart, consider an option for tagging in such a way that it will be auto-added (food for thought anyway, maybe doesn't apply...).
Rob -
Strange Problem in dynamically list population with record group
Hello Room,
I am dynamically populating a single list with 2 record groups. I am having a strange problem. All the code are written in 2 seperate buttons. The code of every button is given below.
Button 1 code:-
DECLARE
rg_reports RECORDGROUP;
rg_name VARCHAR2(40) := 'REPORTS';
vTemp NUMBER;
BEGIN
-- Pls make sure Group doesn't already exist
rg_reports := FIND_GROUP(rg_name);
-- If it doesn't exist then create it and add ur query to it
IF Id_Null (rg_reports) THEN
rg_reports:=CREATE_GROUP_FROM_QUERY(rg_name , 'SELECT companyname,to_char(co) from companymaster order by companyname');
end if;
--Populate the Record Group
vTemp:=POPULATE_GROUP(rg_reports);
POPULATE_LIST('REPORTS.EXAMPLELIST', rg_name);
Delete_Group( rg_reports );
END;
Button 2 Code:-
DECLARE
rg_reports RECORDGROUP;
rg_name VARCHAR2(40) := 'REPORTS';
vTemp NUMBER;
BEGIN
-- Pls make sure Group doesn't already exist
rg_reports := FIND_GROUP(rg_name);
-- If it doesn't exist then create it and add ur query to it
IF Id_Null (rg_reports) THEN
rg_reports:=CREATE_GROUP_FROM_QUERY(rg_name , 'SELECT accountname,to_char(co) from accountmaster order by accountname');
end if;
--Populate the Record Group
vTemp:=POPULATE_GROUP(rg_reports);
POPULATE_LIST('REPORTS.EXAMPLELIST', rg_name);
Delete_Group( rg_reports );
END;
The code is same here only the sql is different in these 2 buttons. Now the problem point.
when i press button 1, I get the list populated ok. when i try to click on the list item and keep the button pressed the list gets scrolled properly.
when i press button 2 after that i get account names well populated in the same list item as well, but this time, when i keep the button pressed the list does not scroll below as in button 1. It does not even allow to select different item from the list of button 2 code.
I tried to clear cache, cookies, exit browser everything and try to run the button 2 first, but still the problem in button 2 code.
Following are my system details.
windows 7 professional edition.
Oracle database 11g on windows 7
Oracle forms 10g patchset 10.1.2.0.2 on windows 7
Browser Netscape Navigator with oracle jinitiator 1.3.1.22
But this form is run by a client side html file where oracle forms 10g is not installed on windows xp. html file is just referring server url to run the module. The file is run on Netscape navigator browser with oracle jinitiator 1.3.1.22
My question is that is this a bug ? if button 1 gets the list item scrolled, why is the problem with button 2 even though i press it first. Here I am deleting the record group also. after the code is over. Initially I thought this may be the character length problem so I took the maximum character length for that list item as given by the 2 columns in database.
Why is the list scrolling not happening in button 2 but in button 1 with same codes on both ?
Anybody please help me.The problem is the second query. I would guess that the TO_CHAR(co) is not unique for each account, but is the same for the accounts. And as the second item in the select-list is the listitems values, all your listitem-entries have the same value. therefore, of you select any entry, the list will always go the the first entry again.
Adjust your query.
Maybe you are looking for
-
Editing raw photos in CS4 and returning to a specific event in Iphoto '09
I wish to edit raw photos in CS4. I have set CS4 as my preferred editor in preferences. When I am finished editing in CS4, I wish to to return the edited photo to the same event from which it came. How do I do this without saving the photo to the des
-
iframe link to #anchor only works the second time
I am exploring a way of delivering a local HTML file into a Web Content frame in such a way that it starts at a specific HTML anchor rather than the top of the HTML page. Now, since DPS's Web Content overlay does not support the URL+anchor string for
-
after creatinga bpel process which is using a dataBase adpater I get the following exception when trying to test the process from the em: Non Recoverable System Fault: faultName: ((http://schemas.oracle.com/bpel/extension) bindingFault) parts: ((summ
-
Dbconsole start failed on Oracle 11G
After installing Oracle 11G and creating a new database, I have created new db console reporsitory, with the commands: set ORACLE_SID set ORACLE_HOME set SYS_PWD set PORT emca -repos create -silent -SID $ORACLE_SID -ORACLE_HOME $ORACLE_HOME -SYS_PWD
-
We are getting the error below on transactions since we applied the SPS 12. It happens when there isnt any activity inside of the portal for about 3-5 mins. After that time has elapsed, any transaction you click on will display this error. If anyon