ODI 11 g | Passing the value of the variable ODI option procedure

Hi Experts,

I need to pass the value of the global variable / project to an option of the procedure and in the application of the procedure to retrieve. Procedure will be implemented in jython.

How can I pass the value of the variable option procedure ODI & then retrieve it in the jython script?

Model data source is the flat file based & I want to retrieve the location of the source directory using jython/java (must implement an on file preprocessing step before calling the interface to load). Is there an ODI API to retrieve the location of the source directory?

Thank you
Ashish

The reason OdiGetOption won't work because odigetoption running will search for the name of the variable where like everything using the execution variable will look at the value of the variable.
In order to manage your situation i belive, we can establish by using the combination of getoption and global variable using the if condition

You can write code something like that
If odigetoption == 'dat ':
ctrlfileExt = #v_CtrlFileExt
If odigetoption == "txt":
ctrlfileExt = #v_CtrlFileExtTxt

This way, when you call the procedure, you can supply the value of the extension and procedure will use the right variable and the value.

I hope this helps.

Tags: Business Intelligence

Similar Questions

  • How to pass the variable in a procedure as parameter

    CREATE OR REPLACE PROCEDURE APPS. "" QFJS_LMO_TIMESLOT_PROC ".
    (
    a_std IN VARCHAR2,
    TYPE str_table IS TABLE OF CLOB directory INDEX;
    timeStr OUT str_table;

    )

    It's in error!

    Help, please!

    That's what you're looking for? (you can also create the type of your database)

    CREATE OR REPLACE PACKAGE APPS.MY_PACKAGE AS
      PRAGMA SERIALLY_REUSABLE;
    
      TYPE str_table IS TABLE OF CLOB INDEX BY BINARY_INTEGER;
      PROCEDURE "QFJS_LMO_TIMESLOT_PROC"(a_std             IN VARCHAR2,
                                         post_std          IN VARCHAR2,
                                         a_time            IN VARCHAR2,
                                         post_hc           IN NUMBER,
                                         pre_hc            IN NUMBER,
                                         ods_schedule_date IN DATE,
                                         timeStr           IN OUT str_table);
    END MY_PACKAGE;
    /
    CREATE OR REPLACE PACKAGE BODY APPS.MY_PACKAGE IS
      PRAGMA SERIALLY_REUSABLE;
    
      PROCEDURE "QFJS_LMO_TIMESLOT_PROC"(a_std             IN VARCHAR2,
                                         post_std          IN VARCHAR2,
                                         a_time            IN VARCHAR2,
                                         post_hc           IN NUMBER,
                                         pre_hc            IN NUMBER,
                                         ods_schedule_date IN DATE,
                                         timeStr           IN OUT str_table) IS
    v_clob clob;
    
      BEGIN
        FOR i IN 1 .. timeStr.COUNT LOOP
          v_clob := timeStr(i);
          -- ...
        END LOOP;
      END "QFJS_LMO_TIMESLOT_PROC";
    BEGIN
      NULL;
    END MY_PACKAGE;
    /
    
    BEGIN
      APPS.MY_PACKAGE.QFJS_LMO_TIMESLOT_PROC('1','2','3',4,5,sysdate,APPS.MY_PACKAGE.str_table('clob1', 'clob2', 'clob3'));
    END;
    / -- Hugs, Philips
    
  • How to pass the variable in the table?

    Hello. I try to pass the variable created in RTF and after I enter in the table.

    In RTF:

    <? xdoxslt:set_variable($_XDOCTX,_'var',500)? >

    After the table:
    chart:
    .....................
    < DataValues >
    < RowData >
    [< xsl: for each groupe-select=".//ROW[Edad16]" group by = "Edad16" xmlns: xsl = "http://www.w3.org/1999/XSL/Transform" > ".
    < cell >
    xdoxslt:get_variable($_XDOCTX,_'var')
    < / cell >
    < / xsl: for each group->
    < / RowData >
    < RowData >
    [< xsl: for each groupe-select=".//ROW[Edad16]" group by = "Edad16" xmlns: xsl = "http://www.w3.org/1999/XSL/Transform" > ".
    < cell >
    50
    < / cell >
    < / xsl: for each group->
    < / RowData >
    < / DataValues >
    < / LocalGridData >
    < / chart >

    And it isn´t work :-(

    Any ideas?

    Hi, Benito,.

    It wil work

     
    
  • How to pass a value to a variable at the time of the execution of the script

    Hi all

    I need to establish an ODI scenario, with below requriments.

    I have to move the data from flat file to target DB.

    flat file name is not consistent, it must pass the file at the time of the excution of scenario name.

    All could help me how to build this ODI scenario.

    Appreciate your help.

    In the data store where the filename in the "name of the resource', you enter a variable #myVar

    You must recompile your script after that this change was made.

    And when you run the script, follow the «-Project.myVar=c:\filename.txt settings.

    Probably, this link may help you http://blogs.oracle.com/dataintegration/2009/04/using_parameters_in_odi_the_dy_1.html

  • If it is possible to pass the variable of type table in sceduler.

    Hello

    need to schedule a task to call a procedure but procedure a array as a parameter.

    Let me know we can pass the type of object as a parameter in the Scheduler.

    procedure definition: procedure (number, varchar2, ch. pakage.table_type b)

    I don't think that you can do with a PL/SQL type in a package, but you can do it with a SQL type, as shown below.

    Scott@orcl12c > test_tab CREATE TABLE

    2 (col1 NUMBER,

    VARCHAR2 (30) 3 col2.

    col3 4 VARCHAR2 (30))

    5.

    Table created.

    Scott@orcl12c > CREATE or REPLACE TYPE table_type AS TABLE OF VARCHAR2 (30);

    2.

    Type of creation.

    Scott@orcl12c > test_proc CREATE OR REPLACE PROCEDURE

    2 (a NUMBER;

    3B VARCHAR2,

    4 c. table_type)

    5 AS

    6 BEGIN

    7 BECAUSE I have 1... c.COUNT LOOP

    8 INSERT INTO test_tab (col1, col2, col3) VALUES (a, b, c (i));

    9 END OF THE LOOP;

    10 END test_proc;

    11.

    Created procedure.

    Scott@orcl12c > SHOW ERRORS

    No errors.

    Scott@orcl12c > START

    2 DBMS_SCHEDULER. CREATE_JOB

    3 (job_name-online 'test_job',

    job_type 4-online "procedure_stockee."

    5 job_action-online 'test_proc. "

    6 number_of_arguments-online 3);

    7 DBMS_SCHEDULER. SET_JOB_ARGUMENT_VALUE

    8 (job_name-online 'test_job',

    argument_position 9-online 1.

    argument_value 10-10 online);

    11 DBMS_SCHEDULER. SET_JOB_ARGUMENT_VALUE

    12 (job_name-online 'test_job',

    13 argument_position-online 2

    14 argument_value-online 'test');

    15 DBMS_SCHEDULER. SET_JOB_ANYDATA_VALUE

    16 ("test_job", 3, sys.anydata.convertCollection (table_type ("Oracle", "database")));

    17 DBMS_SCHEDULER. SELECT ("test_job");

    18 END;

    19.

    PL/SQL procedure successfully completed.

    Scott@orcl12c > DBMS_LOCK EXEC. SLEEP (5)

    PL/SQL procedure successfully completed.

    Scott@orcl12c > SELECT * FROM test_tab

    2.

    COL1 COL2 COL3

    ---------- ------------------------------ ------------------------------

    10 test Oracle

    test 10 database

    2 selected lines.

  • by passing the variable char in the sliders

    HI I try to move the tank for the cursor variable, but it is not taking, if I hardcode the values of the slider that he takes

    Here's detailed... any body can say why it is not taken and tell me how to pass the values through it...

    declare
    v_Name tank (6);
    cursor c1 (c_name tank) is
    Select name, parent, child, relationship status
    First name = '% '.
    Connect prior parent child =
    Union
    Select name, parent, child, relationship status
    First name = '% '.
    connect by prior child = parent
    order by 2;
    v_c1 c1% rowtype;
    Start
    v_Name: = ('A');
    Open c1 (v_name); - here the value of v_name does not... If like hard-code open c1('c'); then work... I need to pass - value not hardcode
    Fetch c1 in v_c1;
    dbms_output.put_line (v_Name);
    dbms_output.put_line (' name ' |' parent ' |' child ' | ' status "");
    While c1%
    loop
    dbms_output.put_line (v_c1.name |) » '|| v_c1.parent | | » '|| v_c1. Child | | » '|| v_c1. Status);
    Fetch c1 in v_c1;
    end loop;
    Close c1;
    en

    Try it with a varchar2 variable (6)

    declare
    v_name varchar2(6) ;
    cursor c1(c_name varchar2) is
    select name, parent,child,status from relation
    start with name='%'
    connect by prior parent=child
    union
    select name, parent, child , status from relation
    start with name='%'
    connect by prior child=parent
    order by 2;
    v_c1 c1%rowtype;
    begin
    v_name :=('A');
    open c1(v_name);---Here the v_name value is not taking.. if hardcode like open c1('c') ; then working.. i need to pass -- value not hardcode
    fetch c1 into v_c1;
    dbms_output.put_line(v_name);
    dbms_output.put_line('name '||'parent '||'child '||'status ');
    while c1%found
    loop
    dbms_output.put_line(v_c1.name||' '||v_c1.parent||' '|| v_c1.child||' '||v_c1.status);
    fetch c1 into v_c1;
    end loop;
    close c1;
    end
    
  • How to pass the variable to bind page ADF view object

    Would appreciate your help on this.
    Set up a view with a variable binding object: param1 in where clause.
    I want to pass the value of the variable to link from a page of the ADF (.jspx)

    I know that one Option using executeWithParams() method binding in the ADF page.
    But, I want to pass a pageFlowScope parameter (which is already set when loading the page) to the variable binding VO, and the VO should also display the results filtered on the page the first time itself.

    Could someone help me understand with a code, how to achieve the same. (Is there a groovy expression to access the param pageflowscope?)

    Thank you

    Published by: user5381160 on August 12, 2010 20:01

    You should also consider dragging operation executeWithParams on your workflow and of wiring to occur before your page instead of in the definition on the page itself - so it is more clear what is happening and is the approach recommended for 11 g applications. When drag-and you - drop operation, you can use the dialog box bind the parameter to your page flow - scope variable by providing the good EL there.

    There is no expression Groovy in the model layer to access the workflow variable scope page (which is in the controller layer) because this would violate the separation of concerns inherent in an MVC application.

    John

  • How to pass the variable to a swf into another swf

    I declared a variable in the one.fla file

    I open another file swf on a button.

    the code is as follows

    name = 'personName ';

    myButton.onRelease = function () {}

    trace ("liberation" + name);     personName

    loadMovie ("mainPage.swf", _root);

    _root.loadMovie ("mainPage.swf");

    }

    I want the variable 'name' of access to another swf file. IE (mainPage.swf)

    How do I do that?

    You want to use the MoveClipLoader class (using loadClip() and addListener methods) rather than loadMovie so that you can wait for the file to load before you try to access anything in it.  You can create an empty movieclip to load the SWF in, and in this way the loaded file can be targeted using the empty movieclip instance name.

  • by passing the variables or targeting aray instance



    I can enter the variable in Pages.as now, but the charger will not "recharge" hen is click on the button...

    Stayed in it for too long and could use some help. Thanks in advance to anyone out there with a bone to throw away a newbie.

    God is in the details.

  • How can I pass a value to a variable binding in a report query?

    I did a query of report to print a PDF report, with a dinamyc source query that has a connection variable, like this:

    SELECT EMPNO, EMPNAME, EMPDEPT

    FROM EMP

    WHERE EMPNO =: PARAMETER;

    I want to call the report print directly from a page, by using the url print showed by apex:

    f? p = & APP_ID.:0 : & SESSION. : PRINT_REPORT = MYREPORT

    How can I pass the value of the variable binding: PARAMETER using this URL?

    I don't think you can use the url parameter passes in a report query.

    the binding variable: PARAMETER must be a page element or an element of the application.

    use the "include session information and application" in the defination of report query to bind the value when the report is run

  • @HspNumToString () cannot pass the variable as a parameter?

    Hi all

    I create a rule that uses @HspNumToString () and pass a variable as a parameter.

    But it gives error on validation below the code associated with the @HspNumToString function.

    Var itemCounter = 1;

    ...

    DIFFICULTY ({UserEntity}, {period}: Dec,@MEMBER (@CONCATENATE ("Item", @HspNumToString (itemCounter))))

    ...

    ENDFIX

    and the error message is:

    "Error: formula [statement of DIFFICULTY] (line 97) parse error: invalid object type rule.

    IF I move a number as a parameter to @HspNumToString (), for example @HspNumToString (2) then the rule will be valid.

    Any suggestion?  Calculation Manager version is 11.1.2.4.001

    Best regards, Brian

    Hello

    I'm afraid that's how it is. You cannot use variables of calculation in trouble.

    Instead, you can set a static member of this dimension (i.e. "no element") and by your use of calculation an operator cross dimensional to calculate the item desired.

    See you soon,.

    Alp

  • Pass the variable null

    Hello

    I have a script to create a new hard drive for the virtual machine

    How to change my script to skip the creation of hard drive if the cell of hardisk1 does not have a value (empty)!

    $harddisk1 = $Data.harddisk1
    $DatastoreName1 = $Data.DatastoreName1

    $Name | New-harddisk - CapacityGB $harddisk1 - data store $DatastoreName1-persistence persistent

    Capture.PNG

    Hello, VicMware-

    You can simply wrap a conditional statement around that to verify that the values for harddisk1 and DatstoreName1 are non-empty string values non-zero.  As:

    ## if neither item is null or an empty string, then add the new hard diskif ($Data.harddisk1 -and $Data.DatastoreName1) {    "Ok, will do something for $Name"    $harddisk1 = $Data.harddisk1    $DatastoreName1 = $Data.DatastoreName1    $Name | New-HardDisk -CapacityGB $harddisk1 -Datastore $DatastoreName1 -Persistence persistent} ## end if## else, do something elseelse {"hm, maybe missing some data for VM $Name"}
    

    Or, if you want to be a little more explicit with the line that checks the value null or empty, you can replace the line 'if' above with:

    if (![string]::IsNullOrEmpty($Data.harddisk1) -and ![string]::IsNullOrEmpty($Data.DatastoreName1)) {...
    

    Those who should be working [almost] identical.  How do for you?

  • Pass the variable to the embeded swf format

    Hello

    I have a flash movie that uses a loader to load another flash animation. How can I pass variables from one film to the other, without using global variables?  For any help or suggestion would be greatly appreceated.

    If you load another as3 swf, you can reference variables using the correct path.  the main scenario for the loaded swf file is the property of content of your charger (cast as a movieclip).

    If you load an as2 swf, you must use localconnection to communicate between the two rulers.

  • How to pass the variable in the lov using like operator SQL

    Hello.
    I want to use a lov I pass a variable using like operator.
    my query is
    Select empno, name of the table where empno as ': ed %';

    I want to show a % or B empno % so my empno is A001 to A199 AND B001 to B199
    How can I do this?


    regards

    Set the property default_where to the block and run the query

    set_block_property ('myblock ', default_where,' like upper (Ename)' |: mybind |) » %');

  • How to save and pass the variable to the BindingInfo resources xWebSite DSC setting.

    Let's say I want to share data and configuration and I would love to sites linking information in the DSCConfigurationdata file, separately from DSC configuration like this:

    xWebsite xWebsite1
    {
    Name = "site.name.com".
    ApplicationPool = "site.name.com."
    Ensure = 'Present '.
    PhysicalPath = "C:\Inetpub\wwwroot\site.name.com."
    State = "started".
    BindingInfo = $Node.BindingInfo
    }

    and DSCConfigurationdata file will contain something following:

    BindingInfo = @)
    @{
    Protocol = "HTTP".
    Port = 80
    IPAddress = "1.1.1.1".
    Hostname = "site.name.com."
    },
    @{
    Protocol = 'HTTPS '.
    Port = 443
    IPAddress = "1.1.1.1".
    Hostname = "site.name.com."
    CertificateThumbprint = "54634563456345."
    NomMagasinCertificat = "accommodation".
    }
    )

    [But since BindingInfo must be of type [CimInstance []]] and it's resource set instance specific ICD I can instantiate and create an array of items of CimInstance (actually MSFT_xWebBindingInformation class).

    So can anyone please can help me on how to do this.

    Thanks in advance.

    JK

    This issue is outside the scope of this site and must be placed on Technet or MSDN

Maybe you are looking for