Functions OdiRef

Hello

I would like to know if there is documentation on the OdiRef functions.
I load a .csv file into an oracle table, but I would like to delete all my cvs file before empty lines. Or if someone has another solution...

Thank you

These 2 documents can help you
http://www.Oracle.com/technology/products/Oracle-data-integrator/10.1.3/htdocs/documentation/oracledi_jython_reference.PDF
http://www.Oracle.com/technology/products/Oracle-data-integrator/10.1.3/htdocs/documentation/oracledi_api_reference.PDF

If I understand, you want to remove all empty lines of csv files before loading to Oracle. Right? You can maybe use Jython code for this.
But out of curiosity, why do you do this?

Tags: Business Intelligence

Similar Questions

  • Nested functions odiRef

    Hello

    I want to use an odiRef function in another function odiRef to determine the name of the database server that is bound to a certain model - and I want to recover the dynamic context Code. Based on the documentation that I have reviewed, this should be possible, but it does not work for some reason any. Did anyone see what I have to change?

    This code is inside a variable:

    SELECT '< %=odiRef.getCatalogName ('Essbase-ODI-Test", odiRef.getSession ("CONTEXT_CODE"),"D") % >' FROM dual

    The error message is:

    com.sunopsis.tools.core.exception.SnpsSimpleMessageException: error in the interpretation of the task
    Task: 1
    java.lang.Exception: BeanShell script error: parse error at line 2, column 10. Met: (info OSB: null to the line: column 0: columnNo)
    ...
    Text: SELECT ' <? = snpRef.getCatalogName (' Essbase-ODI-Test "," <? ") = snpRef.getSession ("CONTEXT_CODE")? (">", "D")? > ' FROM dual
    at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep (SnpSessStep.java)
    to com.sunopsis.dwg.dbobj.SnpSession.
    ...


    Thank you
    Matt

    I'm not sure that you can nest api orders because of the way they are converted during execution (someone can correct me if I'm wrong), I created 2 variables a get the context code then the second would use the first variable in there.

    In any case, saying that you are sure that you want to use odiRef.getSession ("CONTEXT_CODE") as if you use

    SELECT '< %="odiRef.getCatalogName" ("essbase-odi-test",="" "d")="" %="" >="" '="" de="" la="">

    He'll be looking for the current context that is used in the execution, so you don't really have the getSession ("CONTEXT_CODE")

    See you soon

    John
    http://John-Goodwin.blogspot.com/

  • Issue with &lt; %=odiRef.getSysDate ("yyyyMMddHHmmss") % &gt;

    Dear all,
    I'm interfaces migration from DB2 to Oracle. I use the function < %=odiRef.getSysDate ("yyyyMMddHHmmss") % > in a mapping in the target data store.

    When I run the interface, I get an error saying "936: 42000: java.sql.SQLException: ORA-00936: lack of expression.

    What is the value returned by the function above. I will use the above only function in the map. Please help solve the problem.

    Hi Jr,

    Use only the sydate Word, I mean:

    "sysdate" instead of "%=odiRef.getSysDate ("yyyyMMddHHmmss") % of <> .

    Works?

    Cezar Santos
    [www.odiexperts.com]

  • Use a function in a mapping on ODI 12 c

    Hello

    I need help... I got a package in the database and this package have a function inside and I need to use this function in a field in my correspondence.


    I proved to use but without running...

    < %=odiRef.getObjectName ("PROD_GUUIDPROD_PKG. SYS_GUID_FUM") % >

    The name of the package is 'PROD_GUUIDPROD_PKG'

    And the name of the function is 'SYS_GUID_FUM'

    Thank you

    Try to encapsulate your DB function inside a function user of ODI and then refer to the user ODI function in your mapping, the following article gives a good example how to proceed: http://www.ateam-oracle.com/implementing-early-arriving-facts-in-odi-part-ii-implementation-steps/ which provides a good abstraction layer

    Or you can do it directly in the map, but use the following syntax:

    < %="odiRef.getObjectName" (« l »,="" « prod_guuidprod_pkg »,="" « d »)="" %="" >.="">

    (L is, it's a logic diagram D is development environment)

  • How to use odiRef.getJDBCConnection ("WORKREP") to store the data in ODI Vars

    [blog | http://bahchis.com/2011/03/03/odi-repositories/] Sergei Bahchissaraitsev

    Hello world

    In this blog, I saw the new 11g feature to get the JDBC connection to the working repository object. I really want to use it in an ODI variable. Specifically, I want to read the current operator logs in the repository of work and store that value in a Variable ODI.

    Previously I used the topology to guide me to the correct working repository, but it's heavy. I want to go directly to the repository of current work for my connection, and the new "WORKREP" setting allows this.

    Here is my old code in a variable of ODI. This code requires a schema be installed.

    Select count (*)
    of snp_sess_task_log
    where sess_no = < % = odiRef.getSession ("SESS_NO") % >

    How can I get the same result in an ODI variable by using the odiRef.getJDBCConnection("WORKREP") function to direct me to the correct working repository? Using it would be a huge improvement to how to recover data from the operator in ODI. Appreciate your thoughts.

    Sincerely,

    Chris Rothermel

    Hi Chris,
    Thank you for interest in my blog post on [url http://bahchis.com/2011/03/03/odi-repositories/] repository ODI

    As a short response, there is no native way to do what you ask, that I am aware of the case.
    I also answered in more detail to your comment on my blog, which suggests another method using a link DB, you can follow the link to read it.

    On the procedure of Jython you write, my suggestion would be to avoid it.
    Engine in memory is a little less accessible since apart from ODI, it is harder to monitor what is happening exactly in there. I've lived and seen very bad practices involving Jython and the In-Memory engine.
    For example, the table could continue to grow at each execution of the script, probably without notice, given that this is not something that you look at every day.

    Sergey.

  • error by calling the pl/sql function in column target

    Hi guys,.

    I get this error when my function in ODI:

    Caused by: java.sql.SQLSyntaxErrorException: ORA-00904: "mySchema". "" GET_ODI_DEFAULT_VALUE (1) ": ongeldige ID-> 1 is a parameter

    While in sql developer, I get a good result with the following query:

    Select mySchema.get_odi_default_value (1) double;


    In my target for the primary key table, I call a sequence of mySchema, and it works fine.

    I tried the synxtax following in my target column mapping:

    -< % = odiRef.getObjectName ("" "," GET_ODI_DEFAULT_VALUE (1) "", "D") % >
    -< % = odiRef.getObjectName ("L", "GET_ODI_DEFAULT_VALUE", "D") 1% >

    Thanks for you advice

    You use in the interface? If that's when you come to write the name of the function and make its contribution. It should return the value. As
    GET_ODI_DEFAULT_VALUE (1)

  • odiRef.getColList ("", "[column]", ",", "", "UK") can not get column names

    creating index < %=odiRef.getTable("L",_"INT_NAME",_"W").replaceAll ((char) 34+"\Q%INT_PRF"+odiRef.getInfo("TARG_NAME") + \E "" + (char) 34, (char)34+"%INT_PRF"+odiRef.getInfo("TARG_NAME")+"_IDX"+(char)34) % >
    on < % = odiRef.getTable ("L", "INT_NAME", "W") % > (< % = odiRef.getColList ("", "[column]", ",", "", "UK") % >)
    < % = odiRef.getUserExit ("FLOW_TABLE_OPTIONS") % >

    Copy the following code generates this sql:

    creating index ODI_DEV. I _TARGET_TABLE_IDX $
    on ODI_DEV. I HAVE$ _TARGET_TABLE)
    NOLOGGING


    you see, that there is no column name after statement...
    I have no problems with other functions of the odi...

    What is the problem you think?

    Yes... Otherwise, the column list will be empty for the create index statement

  • With the help of analytical functions

    Hi all

    I'm using ODI 11 g (11.1.1.3.0) and I'm doing an interface using analytical functions in the column map, something like below.
    Salary on (partition of...)

    The problem is that when ODI saw the sum he considers this an aggregate function and the group. Is it possible to understand that it is not an aggregate in ODI function?


    I tried to create an option to specify whether it is analytic, then updated IKM with no luck.
    < % if (odiRef.getUserExit("ANALYTIC").equals("1")) {% >}
    < %} else {% >}
    < % = odiRef.getGrpBy (i) % >
    < % = odiRef.getHaving (i) % >
    < %} % >

    Thanks in advance

    Seth,

    Try this thing posted by Uli:
    http://www.business-intelligence-quotient.com/?p=905

  • Using the data logged in an interface with the aggragate function

    Hello

    I'm trying to use logged data from a source table in one of my interfaces in ODI. The problem is that one of the mappings on the columns target implies a function (sum) overall. When I run the interface, I get an error saying not "a group by expression. I checked the code and found that the columns jrn_subscriber, jrn_flag, and jrn_date are included in the select statement, but not in the group by statement (the statement group contains only remiaining two columns of the target table).

    Is there a way to get around this? I have to manually change the km? If so how would I go to do it?

    Also I'm using Oracle GoldenGate JKM (OGG oracle for oracle).

    Thanks and really appreciate the help

    Ajay

    "ORA-00979"when the CDC feature (logging) using ODI with Modules of knowledge including the aggregate SQL function works [ID 424344.1]
    Updated 11 March 2009 Type status MODERATE PROBLEM

    In this Document
    Symptoms
    Cause
    Solution
    Alternatives:

    This document is available to you through process of rapid visibility (RaV) of the Oracle's Support and therefore was not subject to an independent technical review.

    Applies to:
    Oracle Data Integrator - Version: 3.2.03.01
    This problem can occur on any platform.
    Symptoms
    After successfully testing UI integration ODI using a function of aggregation such as MIN, MAX, SUM, it is necessary to implement change using tables of Journalized Data Capture operations.

    However, during the execution of the integration Interface to retrieve only records from Journalized, has problems to step load module loading knowledge data and the following message appears in the log of ODI:

    ORA-00979: not a GROUP BY expression
    Cause
    Using the two CDC - logging and functions of aggregation gives rise to complex problems.
    Solution

    Technically, there is a work around for this problem (see below).
    WARNING: Problem of engineers Oracle a severe cautioned that such a type of establishment may give results that are not what could be expected. This is related to how ODI logging is applied in the form of specific logging tables. In this case, the aggregate function works only on the subset that is stored (referenced) in the table of logging and on completeness of the Source table.

    We recommend that you avoid this type of integration set ups Interface.
    Alternatives:

    1. the problem is due to the JRN_ * missing columns in the clause of "group by" SQL generated.

    The work around is to duplicate the knowledge (LKM) loading Module and the clone, change step "Load Data" by editing the tab 'Source on command' and substituting the following statement:
    <%=odiRef.getGrpBy()%>

    with
    <%=odiRef.getGrpBy()%>
    <%if ((odiRef.getGrpBy().length() > 0) && (odiRef.getPop("HAS_JRN").equals("1"))) {%>
    JRN_FLAG, JRN_SUBSCRIBER, JRN_DATE
    <%}%>

    2. it is possible to develop two alternative solutions:

    (a) develop two separate and distinct integration Interfaces:

    * The first integration Interface loads the data into a temporary Table and specify aggregate functions to use in this initial integration Interface.
    * The second integration Interfaces uses the temporary Table as Source. Note that if you create the Table in the Interface, it is necessary to drag and drop Interface for integration into the Source Panel.

    (b) define the two connections to the database so that separate and distinct references to the Interface of two integration server Data Sources (one for the newspaper, one of the other Tables). In this case, the aggregate function will be executed on the schema of the Source.

    Display related information regarding
    Products

    * Middleware > Business Intelligence > Oracle Data Integrator (ODI) > Oracle Data Integrator

    Keywords
    ODI; AGGREGATE; ORACLE DATA INTEGRATOR; KNOWLEDGE MODULES; CDC; SUNOPSIS
    Errors
    ORA-979

    Please find above the content of the RTO.
    It should show you this if you search this ID in the Search Knowledge Base

    See you soon
    Sachin

  • Using user defined global functions

    Hello
    I put implement Error Handling in a package. The logic goes like this:
    If the call to the first interface fails, KO called the proc error using what error message is retrieved, written to a file and an e-mail notification is sent.
    The code below is written in the procedure.

    OdiOutFile-FILE=E:\OraHome_2\oracledi\demo\Assignmnt\ErrorLog.log
    ErrMesg: "< % = odiRef.getPrevStepLog ("MESSAGE") % > '"

    Now, I need to implement using a global function that can be used through interfaces to implement the error handling.
    I want to club the code used above with the sending of a notification by e-mail.

    Can someone pls guide me if I have my approach is correct and how this approach can be implemented using the global function?

    Thank you.

    Published by: RitikaS on December 18, 2009 02:19

    Hi Ritika,

    May I suggest a method?

    Build a package, describe your flow of interface, the (failed) k of each interface, call OdiSendMail.

    In the OdiSendMail set all settings such as mail server, from and to, subject to body of message code below, paste

    Previous step <%=odiRef.getPrevStepLog("STEP_NAME")%> with the session number <%=odiRef.getPrevStepLog("SESS_NO")%> failed with the error message

    * <%=odiRef.getPrevStepLog("MESSAGE")%>. *

    Please look in the operator for more details.

    So, what will the ODI is, it will send a notification to the recipient with the error message, the session number, and the name of the interface.

    Sample:

    Step previous INT_LOAD_AGE with the number of session 1822124 failed with the error message

    17002: null: java.sql.SQLException: IO exception: the network adapter could not establish the connection
    java.sql.SQLException: IO exception: the network adapter could not establish the connection
    at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:125)
    at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:162)
    at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:274)
    at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:328)
    to oracle.jdbc.driver.PhysicalConnection. (PhysicalConnection.java:361)
    to oracle.jdbc.driver.T4CConnection. (T4CConnection.java:151)
    at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32)
    at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:595)
    at com.sunopsis.sql.SnpsConnection.u (SnpsConnection.java)
    at com.sunopsis.sql.SnpsConnection.c (SnpsConnection.java)
    at com.sunopsis.sql.i.run (i.java)
    .

    Please look in the operator for more details.

    Makes sense?

    http://img259.imageshack.us/img259/1704/screenshot003.jpg

    PS: Please close your threads accordingly award points (useful/correct) help experts for you with impatience.

    Thank you
    Guru

  • Using the Dollar sign ($) in an implementation of the user-defined function

    Hi all

    Just a quick question: how would you use a dollar sign ($) in the (Oracle) implementation of a user function? I ask because the table name that I use in the application happens to contain a dollar sign (I$ _FACT_SALES) and post the results I get now, ODI bed the $ as a reference to a variable, the sign $ so my name removed from the table during execution (I_FACT_SALES). Is there something like a backslash or some other character that could be inserted before the $ for him be part of the name of the table?

    Any response would be greatly appreciated.

    Thank you very much
    Marco

    You have 3 options:

    1.) try using the tablename parameter in the following quotations: ' MY$ TABLE "or maybe MY$ $TABLE using double symbol $
    or
    2) 2) I found this snippet: odiRef.getInfo (\\u0022DEST_WORK_SCHEMA\\u0022) + \\u0022.\\u0022,\\u0022\\u0022)?. "So on these lines, so that you can use \\u0022 as a symbol.
    You can see the similar problem/solution/explanation
    Re: Expression regular wierdness - problem with the character $

    or
    3.) change the prefix work Tables in the topology manager > physical schema > Your_Schema
    E$ _, $ CAN, I have$ _ something like ERR_, SRC_, TD4100

    Published by: Ace2 on December 2, 2009 09:57

  • Function numbers for dynamically on average over the last 30 cells

    I am a trader and I have several months of data. I currently have a percentage of the sum of all the victories and defeats by currency pair. I want to create a function that retrieves the last 30 cells of data and creates a percentage I can compare it to the percentage of total victory.

    The cells are empty, unless I have add data in either to the upper or lower row. 1 win and - 1 are losses. 0 means not configured.

    Here's a full month with 20 data cells (cells max per month are 22) of trading days:

    This is the current month:

    I have 16 months of data with percentages of victory for all my data. As you see, I also have winning monthly winning percentages easily in the examples above (with a small division). I really, really want to compile data from the last 30 cells with data to create a winning percentage. It would be necessary to sometimes include 3 different lines of different months of data to create 30 cells with a number inside.

    A friend used the COUNTIF command but I do not have it works for me.

    If there is a different website to request this detail of the question please share that too.

    Thanks in advance,

    B

    Hi Braddon,

    It would be a pretty easy task if the data to be summed up in two columns from a single table and had no gaps, but that doesn't seem to be the case.

    Screenshots of two isolated sets of cells containing two rows (railway of) the data to be summarized, but give no indication where these data will be found in the document does not provide sufficient information to start to find a solution.

    Where are the data stored? You say "data for each month." "Every month" is recorded on another table?... on a pair of rows of the same table different?

    In the image (very vague) I, the factors of complications will gather data from a subset of continually changing several tables on multiple sheets and which specific cell contains the 30 most recent reference and is the one to start the harvest.

    While a few details and clarifications.

    Kind regards

    Barry

  • Scanner HP M277 function seems to arbitrarily arrest

    Since the Mac OS upgrade, I have a strange problem. The function scanner built into the provided Apple, HP M277 printer driver seems to stop arbitrarily. When the button "scan" in the print queue window will be gray. If I go into the preferences system-> printers and Scanners and select the printer M277c6 there and click on the "Scan" button, then open Scanner it will try to open the window of the scanner, but it stall and never finish.

    When I restart the computer scanner function seems to be restored and everything works as it should. Someone has an idea of what's going on here?

    I go on the HP website and downloaded their software HP Easy Start and completely re - configure the printer with it, but still the same problem.

    Also, I reinstalled the Apple HP (19,13) v5.0 driver. But always after a certain period of time, the scanner is therefore more accessible. I was not able to point of pin code if another program is the cause. Any suggestions?

    There was an Apple update to restore scanning for some HP printers earlier today. Did you check App Store updates?

  • I have an iPhone 6 more, an official version of China, it shows a battery indicator when I turn off support, is this normal? I can depulicate this function to another iPhone? I know how?

    I have an iPhone 6 more, an official version of China, it shows a battery indicator when I turn off support, is this normal? I can depulicate this function to another iPhone? I know how?

    I remember reading somewhere on the Apple site in recent years on some models of Chinese iPhone with this capability. No other iPhones display this and there is no way to enable it. I can't find the article which includes this information.

  • In Keynote is regularly lost function undo

    Hello! I have a problem. In Keynote is regularly lost undo function. This happens randomly, and I don't understand why. Maybe it happens in some other iwork apps, but I have not tried yet used. He arrived in the Sierra of macOS. Аnyone have this happen?

    We have no problem with cancellations in any application on any of our Macs. I heard not only reports of one having this problem.

    Perform this procedure for Foundation repair;   Remove the application Keynote, empty the trash, restart the Mac and then re - install Keynote from the Mac App Store.

Maybe you are looking for

  • Satellite A300 - update driver sound failed

    Hello! I would like to know if anyone has had the same error message when you try to install the new update of audio driver on the A300 model."Driver Installation Failed: could not be found for this MEDIA device driver." " If someone has solved the p

  • my windows 7 disc is scratched - then - I download from the internet

    buy windows 7 pro and does not need 64 disk and now I'm doing but is scratched.  can I drop from the internet and use my key

  • Uninstallers / cleaning

    HI: Just found a problem after you uninstall old software. The system configuration / startup? The program still shows upwards, in the start menu. The source folder is empty. Program search returns no results. Is no longer present in the control/appw

  • I need to be reconnected to Skype

    Related to: effective questions get quick help!my account a few years ago. I had about $5. left in the account, but Skype would not work. I'm tired of trying to reactivate the account.take the frustration of it. just reactivate my account! Please, I

  • Licensing issue?

    Hi allPlease I need help, I bought Lightroom 4.0 several months ago and that you have registered the product via the serial number and everything worked very well.After I registered the product my other half has decided to buy the cloud which, at the