Using GET_GROUP_SELECTION For Record Groups in Oracle Forms

发布时间:2016-12-31 7:39:50编辑:www.fx114.net 分享查询网我要评论
本篇文章主要介绍了"Using GET_GROUP_SELECTION For Record Groups in Oracle Forms ",主要涉及到Using GET_GROUP_SELECTION For Record Groups in Oracle Forms 方面的内容,对于Using GET_GROUP_SELECTION For Record Groups in Oracle Forms 感兴趣的同学可以参考一下。

Using GET_GROUP_SELECTION For Record Groups in Oracle Forms

Retrieves the sequence number of the selected row for the given group. Suppose you want to get a particular column value from a record group for the all rows or for particular rows, then you can use get_group_selection built-in to perform the task.

Example:

/*
Built-in: GET_GROUP_SELECTION Example: Return a comma-separated list (string) of the selected part  numbers from the presumed existent PARTNUMS record group.
*/
FUNCTION Comma_Separated_Partnumbers
RETURN VARCHAR2 IS
tmp_str VARCHAR2(2000);
rg_id RecordGroup;
gc_id GroupColumn;
the_Rowcount NUMBER;
sel_row NUMBER;
the_val VARCHAR2(20);
BEGIN
rg_id := Find_Group(’PARTNUMS’);
gc_id := Find_Column(’PARTNUMS.PARTNO’);
/*
Get a count of how many rows in the record group have been marked as "selected"
*/
the_Rowcount := Get_Group_Selection_Count( rg_id );
FOR j IN 1..the_Rowcount LOOP
/*
Get the Row number of the J-th selected row.
*/
sel_row := Get_Group_Selection( rg_id, j );
/*
Get the (VARCHAR2) value of the J-th row.
*/
the_val := Get_Group_CHAR_Cell( gc_id, sel_row );
IF j = 1 THEN
tmp_str := the_val;
ELSE
tmp_str := tmp_str||’,’||the_val;
END IF;
END LOOP;
RETURN tmp_str;
END;



上一篇:一次完整的HTTP请求所经历的7个步骤
下一篇:php 过滤js字符串代码

相关文章

相关评论

本站评论功能暂时取消,后续此功能例行通知。

一、不得利用本站危害国家安全、泄露国家秘密,不得侵犯国家社会集体的和公民的合法权益,不得利用本站制作、复制和传播不法有害信息!

二、互相尊重,对自己的言论和行为负责。

好贷网好贷款