Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Retreive more than one data...

skudApr 16 2011 — edited Apr 17 2011
Hi,

Im new to javascript , i would like to retreive more than one data and populate in more than one field.

But i know the javascript for retreiving only one data.

Application process:
declare
v_ename emp.ename%type;
begin
select ename
into v_ename
from emp
where emp_id = :P1_EMPID;
htp.prn(v_ename);
exception when others then htp.prn('An error occurred retrieving the name');
end;
javascript:
function get_ename(){
var emp_id = document.getElementById('P1_EMPID').value;
var get = new htmldb_Get(null,html_GetElement('pFlowId').value, 'APPLICATION_PROCESS=GET_ENAME’,0);
get.add('P1_EMPID',emp_id);
var gReturn = get.get();
document.getElementById('P1_ENAME').value = gReturn;
}
From above example it retreive only one data ename..

If i retreive more than one data i.e ename,*salary*,*date_of_birth* i.e
declare
v_ename emp.ename%type;
v_sal emp.ename%type;
v_dob emp.ename%type;
begin
select ename,salary,dat_of_birth
into v_ename,v_sal,v_dob
from emp
where emp_id = :P1_EMPID;
htp.prn(v_ename);
htp.prn(v_sal);
htp.prn(v_dob);
exception when others then htp.prn('An error occurred retrieving the name');
end;
then what would be my javascript for above application process i.e retreive more than one data?
can any pls modify the above javascript?


Thanks and regards,
skud
This post has been answered by Vee on Apr 17 2011
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 15 2011
Added on Apr 16 2011
7 comments
225 views