How to pass parameter into extract function (for XMLTYPE)
I have a table PROBLEMXML with XMLTYPE field xml_column. In this column there are several deffinitions for the problem. There is no max amount of deffinitions and it can be no definition at all. I need to return all definitions for every problem as a string wirh definitions separated by ";".
Query
SELECT extract(prob.Def,'/Definitions/Definition[1]/@var') || ';'|| extract(prob.Def,'/Definitions/Definition[2]/@var')
FROM PROBLEMXML j ,
XMLTABLE (
'/problem'
PASSING j.xml_column
COLUMNS probid VARCHAR (31) PATH '/problem/@id',
Def XMLTYPE PATH '/problem/Definitions') prob
where PROBLEM_ID =1;
returns exactly what I want a;m.
But
declare
my_var varchar2(2000) :=null;
n1 number;
n2 number;
begin
n1:=1;
n2:=2;
SELECT extract(prob.Def,'/Definitions/Definition[n1]/@var') || '|'|| extract(prob.Def,'/Definitions/Definition[n2]/@var') into my_var
FROM ETL_PROBLEMXML_STG_T j ,
XMLTABLE (
'/problem'
PASSING j.xml_column
COLUMNS probid VARCHAR (31) PATH '/problem/@id',
Def XMLTYPE PATH '/problem/Definitions') prob
where PROBLEM_ID =1;
dbms_output.put_line(my_var);
end;
returns NULL.
Is there is a way to pass parameter into extract function?
I need to return all definitions for every problem as a string wirh definitions separated by ";".In XQuery, there's the handy function "string-join" for that.
For example :
SQL> WITH etl_problemxml_stg_t AS (
2 SELECT 1 problem_id,
3 xmltype('<problem id="1">
4 <Definitions>
5 <Definition var="var1"></Definition>
6 <Definition var="var2"></Definition>
7 <Definition var="var3"></Definition>
8 </Definitions>
9 </problem>') xml_column
10 FROM dual
11 )
12 SELECT j.problem_id,
13 prob.probid,
14 prob.def
15 FROM etl_problemxml_stg_t j,
16 XMLTable(
17 'for $i in /problem
18 return element r
19 {
20 $i/@id,
21 element d { string-join($i/Definitions/Definition/@var, ";") }
22 }'
23 passing j.xml_column
24 columns
25 probid varchar2(30) path '@id',
26 def varchar2(100) path 'd'
27 ) prob
28 ;
PROBLEM_ID PROBID DEF
1 1 var1;var2;var3
Similar Messages
-
How to pass parameter into transaction iview ?
Hi experts,
I want to know "how to pass parameter into transaction iview ".
Regards,
Krishna Balaji THi Krishna,
Not sure if this can help you.
1) Passing a parameter to a transaction iview (I saw a resolved suggestion)
Passing a parameter to a transaction iview
2) Passing a parameter from the portal to R3 (helpful info for you)
Passing a parameter from the portal to R3
3) Create SAP Transaction iView using SAPGUI for Windows (Great Blog and info about TA Iview)
Create SAP Transaction iView using SAPGUI for Windows
Please check the following link for Transaction Iviews
http://help.sap.com/saphelp_nw2004s/helpdata/en/02/f9e1ac7da0ee4587d79e8de7584966/frameset.htm
Just some info: Portal is basically what the end user can see. What he can do, is still maintain in the backend system. If there are parameters setup already for the user in the backend system (in SU01), then those parameters should still valid for the transaction that the parameters are linked to.
Hope that helps and award points for helpful suggestions.
Ray -
How to pass parameter into a source variable of a invoke activity
I'm an new BPELer, I created a invoke activity to submit Oracle Appplications concurrent program, but I don't know how to pass parameter into source variable.
BTW, I have created the mapper file (.xsl) file.
could anyone tell me how to do that?
Thanks,
VictorHi.
How you start application? I think you send message to webservice(BPEL process is webservice too). So construct message with variable and value.
But I created only processes where input value doesn't matter. I haven't use mapper yet too. -
How to pass parameter into cursor for loop ?
Hi Experts,
I want to pass parameter l_bom_header_tbl(i).assembly_item_name into the for statement below How to achieve this?
for j in 1 .. l_bom_components_tbl.COUNT LOOP
ThanksMaybe i failed to describe in detail,so here i go:
I have two for loops:
for i in 1 .. l_bom_header_tbl.COUNT LOOP --1st For Loop
V_bom_header_tbl.organization_code :='DSC';
V_bom_header_tbl.assembly_item_name:= l_bom_header_tbl(i).assembly_item_name ;
k:=1;
I want to pass parameter l_bom_header_tbl(i).assembly_item_name into the for statement below: How to achieve this?
for j in 1 .. l_bom_components_tbl.COUNT LOOP *2nd For Loop*
v_bom_components_tbl(k).Assembly_Item_name := l_bom_header_tbl(i).assembly_item_name ;
k := k + 1;
end LOOP;
end loop;
end;
I want to pass a paramter into second for loop in such a way that it accepts from the first for loop
for j in 1 .. l_bom_components_tbl.COUNT LOOP -2nd loop
Edited by: ILovePlSql on Mar 22, 2010 12:25 PM -
How to pass parameter to a report for Operator 'LIKE'
I need to pass a parameter to a report for "LIKE" operator. the parameter for "equal to or is in" operator is 'eq':
'https://secure-ausomxfts.crmondemand.com/OnDemand/user/analytics/saw.dll?Go&Path=/shared/Company_AFTA-D78SR_Shared_Folder/Work Order Asset Lookup&Options=r&Action=Navigate&P0=2&P1=eq&P2=Account.TEXT_61&P3=&p4=
What would 'p1' value for 'LIKE' operator?
ThanksHi, Hope the below helps
neq - Not equal to or not in
lt - Less than
gt - Greater than
ge - Greater than or equal to
le - Less than or equal to
bwith - Begins with
ewith - Ends with
cany - Contains any (of the values in &P3)
call - Contains all (of the values in &P3)
like - Is like (Type %25 rather than the % wildcard)
top - In the top n (&P3 contains 1+n, where n is the number of top items)
bottom - In the bottom n (&P3 contains 1+n, where n is the number of bottom
items)
bet - Between (&P3 must have two values)
null - Is null (&P3 must be 0 or omitted)
nnul - Is not null (&P3 must be 0 or omitted)
Venky CRMIT -
Extract function for xmltype replaces ~ (tilde) with ']]]'
Hi,
In 10.2.0.4 when extracting fragment using xpath and extract function is replacing ~ with ]]]. strange thing is, it happens with only one ~ though there are many ~ in the xml.
Has anyone faced similar issue with extract() function ?
Thanks,
vivekThis turned out to be a bug. It was resolved through a patch developed.
-
How to pass parameter into remote system
i'm doing a small testing on remote connection where i need to remotely login to another NT machine by using JAVA code. therefore i need to send over the ctrl-Alt-Del command by using ASCII code as well as the username and password to login to the remote NT machine. My problem is after my JAVA code start up the VNC connection, the ASCII code and parameter passing was executed before the VNC window popup therefore the parameters are not received by the remote end.
Hi oling,
i am really not sure how u can invoke or rather pass parameters to a Remote System thru Java, where no Java server is running.
which Java Api do u use to connect to remote System. How will the remote System understand the serialised bytes transferred thru ur program.
The Bottomline is i am confused how will the connection haapen after all!!!!!!!!!!!!!!!!!!!!!
can u please explain this or rather pass me the Code...
Thanks in advance,
Manja -
How to pass parameter in sql developer for debubing record type
DECLARE
IB_BP_BANK_ACCOUNT_BUF PL/SQL RECORD; ---record type
IP_BP_ID NUMBER;
IOP_ACC_SEQ_NO NUMBER;
OP_ERROR VARCHAR2(200);
BEGIN
IB_BP_BANK_ACCOUNT_BUF := NULL;
IP_BP_ID := NULL;
IOP_ACC_SEQ_NO := NULL;
ORAGTW11.MAINTAIN_BP_BANK(
IB_BP_BANK_ACCOUNT_BUF => IB_BP_BANK_ACCOUNT_BUF,
IP_BP_ID => IP_BP_ID,
IOP_ACC_SEQ_NO => IOP_ACC_SEQ_NO,
OP_ERROR => OP_ERROR
/* Legacy output:
DBMS_OUTPUT.PUT_LINE('IOP_ACC_SEQ_NO = ' || IOP_ACC_SEQ_NO);
:IOP_ACC_SEQ_NO := IOP_ACC_SEQ_NO;
/* Legacy output:
DBMS_OUTPUT.PUT_LINE('OP_ERROR = ' || OP_ERROR);
:OP_ERROR := OP_ERROR;
END;Something like this:
Assuming you have a procedure like this:
CREATE OR REPLACE PROCEDURE abc (p_emp emp%ROWTYPE)
IS
BEGIN
DBMS_OUTPUT.put_line (p_emp.empno);
END;
Then you have to call it from a PL/SQL Block in this way i.e.:
DECLARE
v_emp emp%ROWTYPE;
BEGIN
SELECT *
INTO v_emp
FROM emp
WHERE ROWNUM<=1;
abc(v_emp);
END;
Regards.
Al -
How to pass parameter into sql block?
example code
@script.sql a b c d
Inside script
DECLARE
cursor cur is select col1 from table where col1 in ('a','b','c','d','e');
BEGIN
END;
Not sure 1) The the total number of parameters will be passed at run time
2) Not sure of case, could be lower upper or both....
Please help...do you have different queries which are defined to use different numbers of parameters, OR (more likely) sometimes you just want to pass less parameters?
sqlplus / @file1 "a" "b" "" "" ""
now I only passed 2 "real" params, and 3 blanks. that way, sqlplus still has the values of &3 - &5 defined, and everything works fine. you'lll need either single or double quotes (or perhaps single quotes within double quotes) depending on your os, version, etc. -
Hello friends,
I am displaying values ie, amounts in the screen using write statements here i have to display the
sign left side , i am using Function module 'CLOI_PUT_SIGN_IN_FRONT'
Does anybody help me - How to pass paramter into this Function module.
Regards,
PhaneendraIf you look to the code of the function module, you can see it is condensing the value.
I would make a copy of this function, and remove the condense lines to give the result you want.
data: text1(1) type c.
search value for '-'.
if sy-subrc = 0 and sy-fdpos <> 0.
split value at '-' into value text1.
condense value.
concatenate '-' value into value.
else.
condense value.
endif. -
Post data into Ajax function for Item type plugin
Please advise how to post data into Ajax function for item type plugin
Edited by: Casufi on Jan 16, 2013 7:44 AMCasufi wrote:
Casufi wrote:
Please advise how to post data into Ajax function for item type plugin
Edited by: Casufi on Jan 16, 2013 7:44 AMI used the following code
var get = new htmldb_Get(null, html_GetElement(''pFlowId'').value, ''NATIVE='||apex_plugin.get_ajax_identifier||''', $v(''pFlowStepId''));
get.addParam(''x01'', node.data.key);
gReturn = get.get();You should use this published true ajax API instaed. apex.server.process( pAjaxIdentifier, pData, pOptions ) -
How to pass values from one function to another
Hi,
I am a middle school teacher and a newbie in Flash Actionscript. I am trying to create a countdown timer for use in my class during tests. The start and pause functions work as required, but not the pause button. When I click on the pause button, the timer is reset to 0:00:00. Please help. Here is the code I had written so far:
var Subject1timeLeftHr;
var Subject1timeLeftMin;
var Subject1timeLeftSec;
Subject1start_btn._visible = true;
Subject1pause_btn._visible = false;
Subject1rotor_mc.gotoAndStop(1);
Subject1rotor_mc._visible = false;
Subject1durationHr_txt.text = "0";
Subject1durationMin_txt.text = "00";
Subject1durationSec_txt.text = "00";
Selection.setFocus(Subject1durationHr_txt);
function SubjectdurationHr(SubjectxdurationHr_txt, SubjectxdurationMin_txt)
if (SubjectxdurationHr_txt.length == 1)
Selection.setFocus(SubjectxdurationMin_txt);
function SubjectdurationMin(SubjectxdurationMin_txt, SubjectxdurationSec_txt)
if (SubjectxdurationMin_txt.length == 2)
Selection.setFocus(SubjectxdurationSec_txt);
function SubjectdurationSec(SubjectxdurationSec_txt, SubjectxdurationHr_txt)
if (SubjectxdurationSec_txt.length == 2)
Selection.setFocus(SubjectxdurationHr_txt);
Subject1durationHr_txt.onChanged = function()
SubjectdurationHr(Subject1durationHr_txt,Subject1durationMin_txt);
Subject1durationMin_txt.onChanged = function()
SubjectdurationMin(Subject1durationMin_txt,Subject1durationSec_txt);
Subject1durationSec_txt.onChanged = function()
SubjectdurationSec(Subject1durationSec_txt,Subject1durationHr_txt);
function startcountdown(SubjectxdurationLeft, SubjectxdurationHr, SubjectxdurationHr_txt, SubjectxdurationMin, SubjectxdurationMin_txt, SubjectxdurationSec, SubjectxdurationSec_txt, Subjectxduration, SubjectxstartTime, SubjectxendTime, Subjectxtimer_mc, Subjectxpause_btn, Subjectxstart_btn, Subjectxrotor_mc, SubjectxtimeLeft, SubjectxtimeLeftHr, SubjectxtimeLeftMin, SubjectxtimeLeftSec, SubjectxtimeLeftHr_txt, SubjectxtimeLeftMin_txt, SubjectxtimeLeftSec_txt)
delete SubjectxdurationLeft;
delete SubjectxdurationHr;
delete SubjectxdurationMin;
delete SubjectxdurationSec;
delete Subjectxduration;
delete SubjectxdurationHr_txt.text;
delete SubjectxdurationMin_txt.text;
delete SubjectxdurationSec_txt.text;
SubjectxstartTime = getTimer();
Subjectxtimer_mc.onEnterFrame = function()
if (SubjectxdurationHr_txt.text == Nan || SubjectxdurationMin_txt.text == Nan || SubjectxdurationSec_txt.text == Nan)
else
SubjectxdurationHr = 60 * 60 * 1000 * Number(SubjectxdurationHr_txt.text);
SubjectxdurationMin = 60 * 1000 * Number(SubjectxdurationMin_txt.text);
SubjectxdurationSec = 1000 * Number(SubjectxdurationSec_txt.text);
Subjectxduration = SubjectxdurationHr + SubjectxdurationMin + SubjectxdurationSec;
SubjectxendTime = SubjectxstartTime + Subjectxduration;
SubjectxdurationLeft = SubjectxendTime - getTimer();
if (SubjectxdurationLeft > 0)
SubjectxdurationHr_txt._visible = false;
SubjectxdurationMin_txt._visible = false;
SubjectxdurationSec_txt._visible = false;
Subjectxpause_btn._visible = true;
Subjectxstart_btn._visible = false;
Subjectxrotor_mc._visible = true;
Subjectxrotor_mc.play();
SubjectxtimeLeft = SubjectxdurationLeft / (1000 * 60 * 60);
SubjectxtimeLeftHr = Math.floor(SubjectxtimeLeft);
SubjectxtimeLeftMin = Math.floor((SubjectxtimeLeft - SubjectxtimeLeftHr) * 60);
SubjectxtimeLeftSec = Math.floor(((SubjectxtimeLeft - SubjectxtimeLeftHr) * 60 - SubjectxtimeLeftMin) * 60);
SubjectxtimeLeftHr_txt.text = String(SubjectxtimeLeftHr);
if (SubjectxtimeLeftHr_txt.length < 1)
SubjectxtimeLeftHr_txt.text = "0" + SubjectxtimeLeftHr_txt.text;
SubjectxtimeLeftMin_txt.text = String(SubjectxtimeLeftMin);
if (SubjectxtimeLeftMin_txt.length < 2)
SubjectxtimeLeftMin_txt.text = "0" + SubjectxtimeLeftMin_txt.text;
SubjectxtimeLeftSec_txt.text = String(SubjectxtimeLeftSec);
if (SubjectxtimeLeftSec_txt.length < 2)
SubjectxtimeLeftSec_txt.text = "0" + SubjectxtimeLeftSec_txt.text;
else
delete Subjectxtimer_mc.onEnterFrame;
SubjectxtimeLeftHr_txt.text = "";
SubjectxtimeLeftMin_txt.text = "";
SubjectxtimeLeftSec_txt.text = "";
SubjectxdurationHr_txt._visible = true;
SubjectxdurationMin_txt._visible = true;
SubjectxdurationSec_txt._visible = true;
Subjectxrotor_mc.gotoAndStop(1);
Subjectxrotor_mc._visible = false;
SubjectxdurationHr_txt.text = "0";
SubjectxdurationMin_txt.text = "00";
SubjectxdurationSec_txt.text = "00";
Subjectxpause_btn._visible = false;
Subjectxstart_btn._visible = true;
Selection.setFocus(SubjectxdurationHr_txt);
function pausecountdown(SubjectxdurationHr_txt, SubjectxtimeLeftHr, SubjectxdurationMin_txt, SubjectxtimeLeftMin, SubjectxdurationSec_txt, SubjectxtimeLeftSec, Subjectxstart_btn, Subjectxpause_btn, Subjectxrotor_mc)
delete Subjectxtimer_mc.onEnterFrame;
SubjectxdurationHr_txt.text = String(SubjectxtimeLeftHr);
SubjectxdurationMin_txt.text = String(SubjectxtimeLeftMin);
SubjectxdurationSec_txt.text = String(SubjectxtimeLeftSec);
Subjectxstart_btn._visible = true;
Subjectxpause_btn._visible = false;
Subjectxrotor_mc.stop();
Subject1pause_btn.onRelease = function()
pausecountdown(Subject1durationHr_txt,Subject1timeLeftHr,Subject1durationMin_txt,Subject1t imeLeftMin,Subject1durationSec_txt,Subject1timeLeftSec,Subject1start_btn,Subject1pause_btn ,Subject1rotor_mc);
Subject1start_btn.onRelease = function()
startcountdown(Subject1durationLeft,Subject1durationHr,Subject1durationHr_txt,Subject1dura tionMin,Subject1durationMin_txt,Subject1durationSec,Subject1durationSec_txt,Subject1durati on,Subject1startTime,Subject1endTime,Subject1timer_mc,Subject1pause_btn,Subject1start_btn, Subject1rotor_mc,Subject1timeLeft,Subject1timeLeftHr,Subject1timeLeftMin,Subject1timeLeftS ec,Subject1timeLeftHr_txt,Subject1timeLeftMin_txt,Subject1timeLeftSec_txt);
Subject1cancel_btn.onRelease = function()
Subject1timeLeftHr_txt.text = "";
Subject1timeLeftMin_txt.text = "";
Subject1timeLeftSec_txt.text = "";
Subject1durationHr_txt._visible = true;
Subject1durationMin_txt._visible = true;
Subject1durationSec_txt._visible = true;
Subject1durationHr_txt.text = "0";
Subject1durationMin_txt.text = "00";
Subject1durationSec_txt.text = "00";
Subject1timeLeftHr_txt._visible = true;
Subject1timeLeftMin_txt._visible = true;
Subject1timeLeftSec_txt._visible = true;
Subject1pause_btn._visible = false;
Subject1start_btn._visible = true;
Subject1rotor_mc._visible = false;
Subject1rotor_mc.gotoAndStop(1);
delete Subject1timer_mc.onEnterFrame;
delete Subject1durationLeft;
delete Subject1duration;
delete Subject1durationHr_txt.text;
delete Subject1durationMin_txt.text;
delete Subject1durationSec_txt.text;I think you need to spend some time reducing your code to practical levels. You seem to be passing everything in the book to every function and I would guess that probably none of it is necessary. If you declared those variables at the beginning, then you don't need to pass them into any function because they are gobally available to any of the code/functions that follows them. Similarly, if you have textfields on the stage, you do not need to pass those into any functions for the same reason.
I see you making overuse of "delete" (and possibly errant use as well). Probably the only thing you might want/need to use is...
delete Subjectxtimer_mc.onEnterFrame;
Which stops the enterframe activity from firing off, which I will guess is being used to update the textfields that indicate the time.
And that conditional that uses == Nan isn't likely to do anything except wonder what an Nan is. Textfields hold strings, which are quoted. SO unless you have a variable named Nan somewhere that has a String value assigned to it, that conditional won't be doing anything for you. You probably won't need it at all if you get this working properly. -
Pass multiple values as single input parameter into pipelined function
Hi all,
My need is to pass multiple values as single input parameter into pipelined function.
For example - "2" and "3" are values of input parameter "t":
with data as (
select 1 as t from dual union all
select 2 as t from dual union all
select 3 as t from dual union all
select 4 as t from dual union all
select 5 as t from dual
select * from data where t in (2,3)Is it possible at all?Not exactly sure, but usually 'multiple values'+'pipelined function' = some IN-LIST related approach?
See:
SQL> create table data as
2 select 1 as t from dual union all
3 select 2 as t from dual union all
4 select 3 as t from dual union all
5 select 4 as t from dual union all
6 select 5 as t from dual;
Table created.
SQL> --
SQL> CREATE OR REPLACE FUNCTION in_list (p_in_list IN VARCHAR2)
2 RETURN sys.odcivarchar2list PIPELINED
3 AS
4 l_text VARCHAR2(32767) := p_in_list || ',';
5 l_idx NUMBER;
6 BEGIN
7 LOOP
8 l_idx := INSTR(l_text, ',');
9 EXIT WHEN NVL(l_idx, 0) = 0;
10 PIPE ROW (TRIM(SUBSTR(l_text, 1, l_idx - 1)));
11 l_text := SUBSTR(l_text, l_idx + 1);
12 END LOOP;
13
14 RETURN;
15 END;
16 /
Function created.
SQL> --
SQL> select *
2 from data
3 where t in ( select *
4 from table(in_list('1,2'))
5 );
T
1
2
2 rows selected.http://www.oracle-base.com/articles/misc/dynamic-in-lists.php
or
http://tkyte.blogspot.nl/2006/06/varying-in-lists.html -
How send parameter in prerender() function for query
Sir I use requestbean for sending data to next page
Because want use this parameter in query
I get data as per this parameter
But when I call next page not pass parameter value to next page and query use blank parameter
I write code in prerender()
See my code
public void prerender() {
try {
getSessionBean1().getTripRowSet().setObject( 1, parameter1..getValue());
tripDataProvider.refresh();
} catch (Exception e) {
error("Cannot switch to person " + “no record “);
log("Cannot switch to person " + “no record , e);
Please give me idea how I send my parameter in prerender() function for query
Thank’s
aamirsir i try SessionBean but same as result
sir you see my full problem
I use studio creator
I create two page first for sending data to other page such as user login page
I add property in SessionBean, RequestBean and bind to data with my user name textfield
and in next page I bind to data with other textfield
after this I try to use this textfield use in
public void prerender() {
try {
getSessionBean1().getChartofaccRowSet().setObject(1, textfield1.getValue());
chartofaccDataProvider.refresh();
} catch (Exception e) {
error("Cannot switch to person " + �noooo�t);
log("Cannot switch to person " + �noooo�, e);
In this line I use that textfiled that bind to data form login page
getSessionBean1().getChartofaccRowSet().setObject(1, textfield1.getValue());
but sir this public void prerender() { function t not get textfield1 value in this function textfield give me null value
but when page complete run then show value in textfield
it mean this public void prerender() { function run befor SessionBean, RequestBean and not get SessionBean, RequestBean value
please give me idea how I pass value in public void prerender() { function form other page and I use this value in query
such as example
getSessionBean1().getChartofaccRowSet().setObject(1, textfield1.getValue());
this is my sessionbean query
SELECT ALL FNET.CHARTOFACC.PARENT,
FNET.CHARTOFACC.CHILD,
FNET.CHARTOFACC.ACCID,
FNET.CHARTOFACC.TITLE,
FNET.CHARTOFACC.CAMPID,
FNET.CHARTOFACC.ACTIVE,
FNET.CHARTOFACC.FSTATUS,
FNET.CHARTOFACC.COMHEADID,
FNET.CHARTOFACC.FIX_VARIABLE,
FNET.CHARTOFACC.VARI_PER
FROM FNET.CHARTOFACC
WHERE FNET.CHARTOFACC.CAMPID = ?
please give me idea
thank�s
aamir
SELECT ALL FNET.CHARTOFACC.PARENT,
FNET.CHARTOFACC.CHILD,
FNET.CHARTOFACC.ACCID,
FNET.CHARTOFACC.TITLE,
FNET.CHARTOFACC.CAMPID,
FNET.CHARTOFACC.ACTIVE,
FNET.CHARTOFACC.FSTATUS,
FNET.CHARTOFACC.COMHEADID,
FNET.CHARTOFACC.FIX_VARIABLE,
FNET.CHARTOFACC.VARI_PER
FROM FNET.CHARTOFACC
WHERE FNET.CHARTOFACC.CAMPID = ? -
How to Pass parameter to Custom Scheduler dynamically
hi ,
I am new to OIM.
Need your help in passing parameters dynamically to Custom Scheduler.
I have created Custom Scheduler by extending Task Support.
I have registered the plugin through API , using PlatformService.registerPlugin() method.
As I need to send the parameter(s) to this CustomScheduler, I have defined them in Metadata (CustomScheduleTask.xml) file as below and got it imported into DB
through weblogicImportMetadata.sh script by providing the path of the file.
<scheduledTasks xmlns="http://xmlns.oracle.com/oim/scheduler">
<task>
<name>CustomScheduleTask</name>
<class>org.schedule.custom.task.CustomScheduleTask</class>
<description>Fetch details of the given user_id</description>
<retry>5</retry>
<parameters>
<string-param required="true" helpText="Login Name">Login Name</string-param>
</parameters>
</task>
</scheduledTasks>
Iam able to import this plugin as well as register the plugin successfully. Now I have defined a job to which this Custom SchedulerTask is mapped.
Now in order to run this job(schedule task) I need to provide Login name( or id) which needs to be send as a parameter for the scheduler to get executed.
But while defining the job with this Schedule Task on OIM console, I was not able to define or pass parameter to this job. hence parameter is null in
CustomSchedule 's execute method .
Kindly help me how to pass parameter dynamically while running the scheduler from OIM console so that the execute method would be able to receive it.
Thank you in Advance.
Regards,
KumarHi,
When you have created the schedule job for your custom schedule task, you should see your Login Name textfield in the schedule task. If not, then there verify your schedule task xml.
In your schedule class code, add:
public void execute(HashMap arg0) {
final String METHOD_NAME = "execute :: ";
logger.debug(CLASS_NAME + METHOD_NAME + "Entering Method - execute");
try {
String LoginName = arg0.get("Login Name");
Regards,
Sunny
Maybe you are looking for
-
Hello, I have a Nokia N97 RM-505 black with firmware v20.0.27 Before updating to 20.0.27, I reset the phone with the so called 3 finger salute: (shift, space, backspace, power button to start), then formatted mass memory, then deleted anything deleta
-
Windows 7 and Advanced Site Setup CS3
This really seems like a dumb question, but I have to ask. Usings DW CS3 under XP, when setting up a new site using the "advanced" tab, you could simply click the folder icon next to "local root folder" and click to either select or create a folder w
-
No entries for org unit, job or position in T5KWB
Hi Experts, I am running payroll for canada , i am getting this error for 2 employees for whom the org assignment been chaged recently - now they are giving , kindly help me - i have checked this table T5KWB and it dosnet hold value maintained for or
-
Unable to read TLD "META-INF/jsf_core.tld
Hi guys, I have Tomcat 5.5.7 and jdk1.5.0_02 on Windows XP Pro ! I am using jsf-1_1_01. One of my page is as below: <%@ taglib prefix="f" uri="http://java.sun.com/jsf/core" %> <%@ taglib prefix="h" uri="http://java.sun.com/jsf/html" %> <f:loadBundle
-
Terminal.app and split-screen
Am I the only one who used the split-screen terminal we had before Leopard? It was great for watching scrolling output since you could keep an eye on new traffic in the bottom of the screen while scrolling back and even searching in the top half of t