XML/XSD question (using ODI)

Hi all.
I have posted this in the ODI forum as well, but this may be a more proper place to ask for help.
I'm working on a new dwh solution where the main source of data will come from XML-files. The problem is that we are having difficulties with the use of abstract types in the xsd-file. We currently use ODI to read the XML-files and to store the data in our database, but all fields from the XML-files are not visible in the target tables.
The problem can be simplified like this example:
We have a main element, testElement, which can contain one or more publications.
Publication is of type PublicationType, and PublicationType is an abstract that contains title, author and date.
We have four other types which extends PublicationType; BookType, MagazineType, NewspaperType and AdsType. They all contain additional fields.
XSD-file
<?xml version="1.0" encoding="UTF-8"?>
<schema xmlns="http://www.w3.org/2001/XMLSchema"
targetNamespace="urn:testing:kontroll:example:oppgave:v1"
xmlns:tns="urn:testing:kontroll:example:oppgave:v1"
xmlns:xdb="http://xmlns.oracle.com/xdb"
elementFormDefault="qualified">
<element name="testElement" type="tns:TestElementType" xdb:defaultTable="TEST_TAB" />
<complexType name="TestElementType">
<sequence>
<element name="publication" type="tns:PublicationType" minOccurs="1"
maxOccurs="unbounded" />
</sequence>
</complexType>
<complexType name="PublicationType" abstract="true">
<sequence>
<element name="title" type="string"/>
<element name="author" type="string" minOccurs="0"
maxOccurs="unbounded" />
<element name="date" type="string"/>
</sequence>
</complexType>
<complexType name="BookType">
<complexContent>
<extension base="tns:PublicationType">
<sequence>
<element name="ISBN" type="string"/>
<element name="publisher" type="string"/>
</sequence>
</extension>
</complexContent>
</complexType>
<complexType name="MagazineType">
<complexContent>
<extension base="tns:PublicationType">
<sequence>
<element name="editor" type="string"/>
<element name="period" type="string" minOccurs="0"
maxOccurs="1"/>
</sequence>
</extension>
</complexContent>
</complexType>
<complexType name="NewspaperType">
<complexContent>
<extension base="tns:PublicationType">
<sequence>
<element name="daily" type="boolean"/>
<element name="owner" type="string" minOccurs="0"
maxOccurs="1"/>
</sequence>
</extension>
</complexContent>
</complexType>
<complexType name="AdsType">
<complexContent>
<extension base="tns:PublicationType">
<sequence>
<element name="company" type="string"/>
<element name="article" type="string" />
</sequence>
</extension>
</complexContent>
</complexType>
</schema>
XML-file
<?xml version="1.0" encoding="UTF-8"?>
<tns:testElement xmlns:tns="urn:testing:kontroll:example:oppgave:v1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="urn:testing:kontroll:example:oppgave:v1 ExampleXMLSchema.xsd ">
<tns:publication xsi:type="tns:BookType">
<tns:title>Boken</tns:title>
<tns:author>Arne Svendsen</tns:author>
<tns:date>2001</tns:date>
<tns:ISBN>78979797</tns:ISBN>
<tns:publisher>The Company Ltd</tns:publisher>
</tns:publication>
<tns:publication xsi:type="tns:MagazineType">
<tns:title>Fancy Magazine</tns:title>
<tns:author>Mads Madsen</tns:author>
<tns:date>2011</tns:date>
<tns:editor>Svante Svantesen</tns:editor>
<tns:period>weekly</tns:period>
</tns:publication>
</tns:testElement>
When tables are generated in the database through ODI I'm not getting all the attributes present in the xml-file.
Can anybody tell me if this should work (and, if yes, why it doesn`t)? Or if the XSD/XML looks wrong in some way?
Is this a known limitation in Oracle or ODI etc.?
Any pointers to documentation describing similar problems would also be helpful.
Thanks,
Bjørn

Hi, Bjørn,
When tables are generated in the database through ODI I'm not getting all the attributes present in the xml-file.I don't know ODI, so I'm just curious here : what tables are generated? Is there one table per extented type (+ child tables for repeating elements), or just one Publication table with missing columns?
I've looked at the other thread you mentioned on the ODI forum, and saw that you'd also want to store XML files in an XMLType table.
I tested the schema registration in the database to see how Oracle reacts to the structure, and it looks OK, type extensions are supported.
SQL> begin
  2   dbms_xmlschema.registerSchema(
  3     schemaURL => 'ExampleXMLSchema.xsd'
  4   , schemaDoc => bfilename('TEST_DIR', 'ExampleXMLSchema.xsd')
  5   , local => true
  6   , genTypes => true
  7   , genTables => true
  8   , enableHierarchy => dbms_xmlschema.ENABLE_HIERARCHY_NONE
  9   );
10  end;
11  /
PL/SQL procedure successfully completed
SQL> insert into test_tab
  2  values (xmltype('<?xml version="1.0" encoding="UTF-8"?>
  3  <tns:testElement xmlns:tns="urn:testing:kontroll:example:oppgave:v1"
  4                   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  5                   xsi:schemaLocation="urn:testing:kontroll:example:oppgave:v1 ExampleXMLSchema.xsd ">
  6    <tns:publication xsi:type="tns:BookType">
  7      <tns:title>Boken</tns:title>
  8      <tns:author>Arne Svendsen</tns:author>
  9      <tns:date>2001</tns:date>
10      <tns:ISBN>78979797</tns:ISBN>
11      <tns:publisher>The Company Ltd</tns:publisher>
12    </tns:publication>
13    <tns:publication xsi:type="tns:MagazineType">
14      <tns:title>Fancy Magazine</tns:title>
15      <tns:author>Mads Madsen</tns:author>
16      <tns:author>Arne Svendsen</tns:author>
17      <tns:date>2011</tns:date>
18      <tns:editor>Svante Svantesen</tns:editor>
19      <tns:period>weekly</tns:period>
20    </tns:publication>
21  </tns:testElement>'))
22  ;
1 row inserted
Querying as relational data :
SQL> select x.*
  2  from test_tab t
  3     , xmltable(xmlnamespaces(default 'urn:testing:kontroll:example:oppgave:v1'),
  4       'for $i in /testElement/publication
  5        return element r {
  6          $i/child::*
  7        , element pubtype {
  8            typeswitch($i)
  9              case element(publication, BookType)      return "Book"
10              case element(publication, MagazineType)  return "Magazine"
11              case element(publication, AdsType)       return "Ads"
12              case element(publication, NewspaperType) return "Newspaper"
13              default return "Publication"
14          }
15        }'
16       passing t.object_value
17       columns title   varchar2(500) path 'title'
18             , authors varchar2(500) path 'string-join(author,",")'
19             , pubdate number(4)     path 'date'
20             , isbn    number(13)    path 'ISBN'
21             , editor  varchar2(500) path 'editor'
22             , period  varchar2(500) path 'period'
23             , pubtype varchar2(30)  path 'pubtype'
24       ) x
25  ;
TITLE                 AUTHORS                        PUBDATE           ISBN EDITOR                PERIOD      PUBTYPE
Boken                 Arne Svendsen                     2001       78979797                                   Book
Fancy Magazine        Mads Madsen,Arne Svendsen         2011                Svante Svantesen      weekly      Magazine

Similar Messages

  • Problem while transferring XML to oracle using ODI

    Hi,
    I need to transform a XML file to Oracle using ODI. i created the target oracle table as usual.
    I read the thread on "http://forums.oracle.com/forums/thread.jspa?messageID=1909900&#1909900" to create an XML model.
    Now my problem is while importing the XML model, in the definition tab, i had given the technology as XML, choosen the appropriate logical shema.
    In the reverse tab, i have choosen global as context and what should i do in the SELECTIVE REVERSE tab.
    I am not getting any KM in the control tab. so what is the KM for XML and how should i get that?
    Please anyone who knows help me...
    Thanks in advance,
    Ram Mohan T.

    When you do the reverse, you should be able to do a "Standard Reverse". No KM is needed for that.
    When you define an interface to move the data, you should use the SQL KMs to access the data in XML. You will need to have these imported in the project where you define the interface.

  • XML Schema Collection (SQL Server 2012): Complex Schema Collection with Attribute - Should xs or xsd be used in the coding?

    Hi all,
    I just got a copy of the book "Pro SQL Server 2008 XML" written by Michael Coles (published by Apress) and try to learn the XML Schema Collection in my SQL Server 2012 Management Studio (SSMS2012). I studied Chapter 4 XML Collection of the book
    and executed the following code of Listing 4-8 Complex Schema with Attribute:
    -- Pro SQL Server 2008 XML by Michael Coles (Apress)
    -- Listing04-08.sql Complex XML Schema with Attribute
    -- shcColes04-08.sql saved in C:\\Documents\XML_SQL_Server2008_code_Coles_Apress
    -- 6 April 2015 8:00 PM
    CREATE XML SCHEMA COLLECTION dbo.ComplexTestSchemaCollection_attribute
    AS
    N'<?xml version="1.0"?>
    <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
    <xs:element name="item">
    <xs:complexType>
    <xs:sequence>
    <xs:element name="name" />
    <xs:element name="color" />
    <xs:group ref="id-price" />
    <xs:group ref="size-group" />
    </xs:sequence>
    <xs:attribute name="id" />
    <xs:attribute name="number" />
    </xs:complexType>
    </xs:element>
    <xs:group name="id-price">
    <xs:choice>
    <xs:element name="list-price" />
    <xs:element name="standard-cost" />
    </xs:choice>
    </xs:group>
    <xs:group name="size-group">
    <xs:sequence>
    <xs:element name="size" />
    <xs:element name="unit-of-measure" />
    </xs:sequence>
    </xs:group>
    </xs:schema>';
    GO
    DECLARE @x XML (dbo.ComplexTestSchemaCollection_attribute);
    SET @x = N'<?xml version="1.0"?>
    <item id="749" number="BK-R93R-62">
    <name>Road-150 Red, 62</name>
    <color>Red</color>
    <list-price>3578.27</list-price>
    <size>62</size>
    <unit-of-measure>CM</unit-of-measure>
    </item>';
    SELECT @x;
    GO
    DROP XML SCHEMA COLLECTION dbo.ComplexTestSchemaCollection_attribute;
    It worked nicely. But, I just found out the coding that was downloaded from the website of Apress and I just executed was different from the coding of Listing 4-8 listed in the book: all the <xs: ....> and </xs: ..> in my SSMS2012 are
    listed as <xsd:...> and </xsd:...> respectively in the book!!??  The same thing happens in the Listing 4-3 Simple XML Schema, Listing 4-5 XML Schema and Valid XML Document with Comple Type Definition, Listion 4-6 XML Schema and XML
    Document Document with Complex Type Using <sequence> and <choice>, and Listing 4-7 Complex XML Schema and XML Document with Model Group Definition (I executed last week) too.  I wonder: should xs or xsd be used in the XML
    Schema Collection of SSMS2012?  Please kindly help,  clarify this matter and explain the diffirence of using xs and xsd for me.
    Thanks in advance,
    Scott Chang   

    Hi Scott,
    Using xs or xsd depends on how you declare the namespace prefix.
      <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
      <xs:element name="item">
    I've posted a very good link in your last question, just in case you might have missed it, please see the below link.
    Understanding XML Namespaces
    In an XML document we use a namespace prefix to qualify the local names of both elements and attributes . A prefix is really just an abbreviation for the namespace identifier (URI), which is typically quite long. The prefix is first mapped to a namespace
    identifier through a namespace declaration. The syntax for a namespace declaration is:
    xmlns:<prefix>='<namespace identifier>'
    If you have any question, feel free to let me know.
    Eric Zhang
    TechNet Community Support

  • Processing XML using ODI

    Hi,
    I'm a novice new to ODI and would like to get answers to few of my questions.
    Scenario
    1) I have a set of XML and the schema(s) associated with them.
    2) Want to process these XML(s) using ODI and storing them in a target DB.
    3) Is it possible to process these XML as real time (i.e. XML(s) messages can come one after another) or ODI is used only for off line activity (e.g. to transfer data from source DB to target, when there are no transactions happening in the source system)
    Is this possible to achive the above functionality using ODI? if yes what would be the constraints associated with it.
    Any document, which talks about it?
    Thanks.

    Am I correct in assuming that you want to load the XML string into your database and not the values contained within the XML structure?
    So if you had:
    <parent>
    <child>
    <value1>1</value1>
    <value2>2</value2>
    </child>
    </parent>
    You would want the entire string rather than values 1 and 2 from the <value1> and <value2> nodes?
    G

  • XML Processing using ODI

    I need to to persist data from xml to Oracle database ? Is it possible using ODI .I dont need to transform the data , I need to actually load it from xml as it is into the RDBMS tables which already exists using ODI , is it possible ? If possible how can I do that ?

    Am I correct in assuming that you want to load the XML string into your database and not the values contained within the XML structure?
    So if you had:
    <parent>
    <child>
    <value1>1</value1>
    <value2>2</value2>
    </child>
    </parent>
    You would want the entire string rather than values 1 and 2 from the <value1> and <value2> nodes?
    G

  • When we use XML,XSD,WSDL files to create SOA webservices in jdeveloper ,what will happen means internally,how will useful xml ,xsd,wsdl for composite ?

    When we use XML,XSD,WSDL files to create SOA webservices in jdeveloper ,what will happen means internally,how will useful xml ,xsd,wsdl for composite ?
    How xml will send message to XSD then how wsdl interaction then to composite ?

    XSD (XML Schema Definition), is an abstract representation of a XML characteristics.
    The WSDL (Web Services Description Language), describes the functionality offered by your web service.
    You can say what operations your services offers, and describe the messages used for this operations in your XSD.

  • Understanding XML file handling in ODI

    Hi People,
    I've just completed a simple Interface to upload an XML file into an Oracle 10g database table. The interface copes well with both inserts and updates, so I'm very pleased about that. ;)
    This exercise has raised some questions though. I tried an experiment, which involved changing an element value in the XML file. I wanted to see if this change would be reflected in the file's associated Source Table in ODI. Unfortunately, it wasn't; despite me clicking the REFRESH button about 4 times. I guess my first question is:
    *1. How can I ensure a change to an element value in the XML file is reflected in ODI, after reverse engineering the associated data store from the file? Is this possible?*
    Moving on, I'm trying to understand the architecture ODI creates in the background, in order to support a source datasource/table that represents the XML file. I have created the following Topology to support the file:
    !http://img2.imageshack.us/img2/6895/odiscr375.jpg!
    As you can see, I've associated the XML file with a physical schema called ODI_XML. This represents a schema owned by my Oracle Database.
    Now, when I check the XML file data in ODI Designer, I notice that it's based on this query:
    select * from ODI_XML.TRADE
    I've checked the ODI_XML database schema, and there is neither a table nor any other objects named TRADE. My next question is therefore:
    *2. Was I correct to assign a database schema (named ODI_XML) to my XML Data Server, or should this have been something else? If so, what?*
    Thanks in advance for any assistance.
    James

    Since you are using the Variable ,when you right click and view datastore its missing the required path of the file, as value of the variable is not determined , to do so you need to either refresh or set the variable and call the interface or other ODI objects and in loop keep reading XML files one by one and that should work.

  • Dynamic generation of HTML based on XML/XSD

    Hi
    I'm looking for a way to generate HTML from various XMLand/or XSD Files. What I want is a generic mechanism that can generate an HTML page from a random XML/XSD File.
    I have one or two ideas, but I'm interested in what others have done so far.
    Questions:
    - Has anybody already made something like this?
    - Is there some free ware API to support this?
    Thanks!

    you can generated the html dynamically and store it in a ABAP variable and use it in your layout
    but in your case one of the best ways you could handle is store the user selections in an internal table. (which can hold the check box number and an indicator whether that should be rendred or not)
    then in the layout write
    <% loop at itab into wa where render = 'X'. %>
    htmlb:checkbox  id= ....
    <% endloop. %>

  • Problem with inserting XML data server in ODI

    Hi,
    I was trying to insert an XML data server in ODI. I want to use it for my target database.i.e i want my target to be an xml file. So while specifying the url in the data server, what should i mention as the file name,dtd file , root etc? what i have done is dat i hav created the dtd file as per my requirement.i have created an empty xml file. while testing the connection an error comes : java.sql.SQLException: A parsing exception occurred saying Whitespace required..
    Next i tried putting jz d root tags in the xml file without any content. this returned the same error. next i tried inserting all d tags as per my dtd file. same error came...
    Please help.
    Regards,
    Divya
    Message was edited by:
    Divya Padmanabhan

    For empty xml try to use:
    <?xml version="1.0" encoding="UTF-8"?>
    <ROOT_SOME></ROOT_SOME>
    as jdbc connect string:
    jdbc:snps:xml?f=../demo/xml/1/file.xml&ro=false&ldoc=true&case_sens=true&s=LEO_FIZ&dod=true
    and try again...

  • Data loading using ODI

    Hi,
    I am using ODI 10g for loading data into oracle 10g database from a flat file. The flat file is in fixed format, but the data is in a single row, so the data is not loaded correctly. For example, 1000 records are shown in 1 line.
    Can someone please suggest, what customization should I make to the IKM to achieve this.
    Please let me know the questions you may have.
    Thanks a lot.

    Hi John,
    I reversed my Planning model and able to see those columns now. I tried executing my interface and got the below error
    The source result set contains column [EMPLOYEE_ACCOUNT] which has no corresponding column on the planning side.
    My source is an oracle table and i have seperate columns for each dimension member. What I did is, mapped the Data column (JobTitle) from source to the Target column(JobTitle) and rest all dimension member columns from source to Point of View column seperated by a comma. My Planning cube name is EMPLOYEE, so in th data cube name column i manually entered "EMPLOYEE" and tried executing it.
    Please guide me as always
    Thanks,
    Sravan

  • In what circumstances would need to use ODI as a complement to a deployment of EDQ?

    Im about to do a presentation about Oracle Enterprise Data Quality and Oracle Data Integrator.
    In my understanding if I use ODI  to do ETL/EL-T tasks, ODI needs EDQ jobs to perform advance Data Quality procesing. In that escenario is perfectly understandable the implementation of both ODI and EDQ solutions.
    If I does not have any solution to do ETL/EL-T task, and my objetive is mainly do data cleansing, (take a set of data, cleaning it, and write the results on a database) why I would need ODI? There is a feature that I could need from it, that I do not have in EDQ for this purpose?
    This doubt came to me, becouse I found a lot of references that makes me think that this two solutions are codependents.
    Thanks for your reply!
    regards.

    Hi,
    This might help. Note that ODI and EDQ are normally sold together for Data Warehousing scenarios, though arguably data profiling, at least, is important in nearly all new projects that use ETL/E-LT technology.
    Some customers, especially MDM customers, do use EDQ for their ETL requirements, as these tend to be simpler than data warehousing scenarios where load plans and data aggregations are important. ODI also has more comprehensive connectivity than EDQ, for example for Mainframe systems.
    We are also seeing a trend for ETL/EL-T to be done strategically in such a way that it rarely needs revisiting for new projects; for example when a new system is onboarded, the key data is replicated or ETL'd into a standard holding area which is then used for any projects which require data from many source systems. This means that EDQ very often takes data output from ETL/EL-T without necessarily being embedded in the ETL or data replication flows.
    Very often both ETL and DQ are required
    It’s not the size or complexity of the transformation that is different, it’s the nature of the transformations – syntax or meaning?
    ODI will do all sorts of denormalisation/normalisation for populating star schemas that would be complex and slow in EDQ
    EDQ will do all sorts of things that improve the business value of the data that ODI would never do
    Data volumes are unlikely to be a guide as to which toolset would be used for a particular task
    Capability 
    Data Quality tools (e.g. OEDQ)
    ETL tools (e.g. ODI)
    Extraction of data from common types of modern database / common file types
    Yes
    Yes
    Native extraction of data from antiquated systems using specific APIs, and data from complex file types, e.g. XML, EBCDIC, EDI, IDoc
    No
    Yes
    Complex extraction rules
    No
    Yes
    Syntactic low-level transformations
    Yes
    Yes
    Data profiling
    Yes
    Basic or none
    Semantic understanding of data
    Yes
    No
    Complex transformations using semantic rules
    Yes
    No
    Complex transformations using non-semantic rules (aggregation, analytical, etc.)
    Possible, but ETL usually preferred
    Yes
    Complex matching and merging
    Yes
    Limited (ETL-type matching/merging) such as exact ID match
    Processing as native SQL on database for optimal performance wherever possible
    Some
    Yes
    Advanced performance parallelisation / distribution / control
    Rare
    Yes
    Multiple source/target mapping
    Some
    Yes
    Writing of data to target systems / staging areas / files
    Yes
    Yes
    Advanced load capability, e.g. single/packet/bulk, load plans etc.
    Rare
    Yes
    Typical users
    Business Users, Consultants, or IT Professionals
    IT Professionals
    Regards,
    Mike

  • Parsing .xsd files using DOM

    Hi,
    I am trying to parse a xsd file using DOM. The xsd has several nodes like
    <xsd:complexType name="AccountLocate">
    I want to extract the strings AccountLocate and AccountCategory and use them for further processing.
    The hierarchy of the nodes is created without issues, but when I try to view the name and value of each node using getNodeName() and getNodeValue() method the node name I get and node value is as follows:
    NODE-NAME NODE-VALUE NODE-TYPE
    xsd:complexType null 1 //corresponds to the xsd:complexType node
    #text 3 //corresponds to the AccountLocate node
    Is there anyway (any DOM method for example) by which I can isolate the name AccountLocate?
    Thanks and regards,
    Prabal

    Which parser is used for parsig?
    With the DocumentBuilder parser set:
    DocumentBuilderFactory factory
    = DocumentBuilderFactory.newInstance();
    factory.setNamespaceAware(true);For parsing with the javax.xml.xpath.XPath class set the NamespaceContext on the XPath object.

  • Is this Possible using ODI / ODQ ?

    Hi ALL,
    Is the below requirement possible with ODI / ODQ?
    (right now I am doing it mannually, and its like a monthly/weekly process)
    If we can do the same using ODQ how I need to start and proceed?
    My requirement is some thing like this. I have two columns
    Address1 (street address)
    Address2 (additional Information)
    In some cases the address is not in the proper format. So I need to do some data cleansing (data scrubbing) before loading using ODI
    Use Address2 if Address1 is PO Box, building name, or any info aside from a street address. Only one address column is needed in the output (Address1)
    For example :
    INPUT
    ADDRESS1--------------------------------------------------ADDRESS2
    HIGHWAY # ------------------------------------------------5010944 MARSH RD
    PO BOX 40964---------------------------------------------1100 AA CORP PARKWAY
    DBA VANTAGE PP---------------------------------------11031 PERRY HIGHWAY
    HOME INFUSION THERAPY SERVICES--------11031 PERRY HIGHWAY
    7275 BUFFALO ROAD----------------------------------(WAS 6855 BUFFALO ROAD)
    7601 N FEDERAL HWY---------------------------------#2506
    MCAS ---------------------------------------------------------(MARINE CORPS AIR STATION)
    212 BRADDOCK AVENUE------------------------------
    212 NINTH STREET----------------------------------------
    2138 JONATHON DRIVE---------------------------------
    OUTPUT (Note : we don&rsquo;t need the Address2 column in the output)
    ADDRESS1----------------------------------ADDRESS2
    10944 MARSH RD------------------------10944 MARSH RD
    1100 AA CORP PARKWAY-----------1100 AA CORP PARKWAY
    11031 PERRY HIGHWAY-------------11031 PERRY HIGHWAY
    11031 PERRY HIGHWAY-------------11031 PERRY HIGHWAY
    7275 BUFFALO ROAD------------------(WAS 6855 BUFFALO ROAD)
    7601 N FEDERAL HWY----------------#2506
    MCAS-----------------------------------------(MARINE CORPS AIR STATION)
    212 BRADDOCK AVENUE------------
    212 NINTH STREET----------------------
    2138 JONATHON DRIVE---------------
    I have posted a similar kind of question in DATA Quality (ODQ) forum
    Forum Home &raquo; Master Data Management (MDM) &raquo; Data Quality
    ADDRESS CLEANING(US) USING ODQ
    Thread: ADDRESS CLEANING(US) USING ODQ
    if any body is working on address cleansing using ODQ, Please guide me to start working on it.
    IS there any specific documents for ADDRESS CLEANING which gives more information about the process flows such as
    Transformer, Customer Data Parser, Sort for Postal Matcher, Postal Matcher, Window Key Generator,Sort for Linking, Relationship Linker, Commonizer, and Data Reconstructor.
    Thanks in Advance,
    Rathish

    Hi Rathish,
    I was building the java code but I got other idea to make more simple.
    1) load the values into a temp table with one column for each address (means 2 columns per line) plus 2 other columns to control.
    Something like:
    table temp_data
    columns: add_1 , control_1, add_2, control_2
    You can do that thru an interface. Let the fields "control" with no value when loaded
    2) create a table to storage the values you sent to me (Avenue, street...)
    table street_names
    columns: street_name, country (to your future use)
    3) Create an ODI procedure (or you can customize a KM with the same technique)
    3.1) Step 1 at target Tab, technology javaScript
    code:
    <@String vU=" ";@>
    3.2.1) step 2 - Tab Source - technology "your database" and the Logical Schema where the "street_names" table as created
    select street_name
    from street_names
    where country = 'US'
    3.2.2) step 3 - Tab Target - tecnology javaScript
    <@vU+="or instr(upper(add_1),upper('#street_name'))>0 ";@>
    3.3) step 3 - Target Tab - technology "your database" and the Logical Schema where the "temp_data" table as created
    <@vU=vU.substring(3);@>
    update temp_data
    set control_1 = 'Y'
    where <@=vU@>
    3.4) step 4 step 3 - Target Tab - technology "your database" and the Logical Schema where the "temp_data" table as created
    <@vU=vU.replaceAll("add_1","add_2")@>
    update temp_data
    set control_2 = 'Y'
    where <@=vU@>
    4) Now you have a table (temp_data) with a flag "Y" where there is a street name and "null" where doesn't exist. Just generate your file by a interface or odiSqlUnload Toll.
    Put all together into a package and you will have your process.
    I create in this way to minimize the access to the temp_table, just 2 updates.
    can be used some alternatives to tunning the hole process if the time doesn't match what you need.
    That is a fast solution. Something more elaborated can be done if necessary.
    Does it help you?
    Cezar Santos

  • Use ODI with JMS Queue

    I'm new user in ODI and also JMS. I successfuly use odi to integrate data from two oracle database applications. I'm trying to integrate applications using JMS Queues (or Topics) and I failed to create odi "data server" for this technology. Can someone help me to do this or give me a sample to follow it?
    thanks.

    Hi there,
    You can actually create 2 different types of connections to a JMS Queue or Topic. Flat or XML. The simplest to start with is flat. This will basically cause ODI to view the contents of the queue as simple flat file data. Note, this is a bit advanced use of ODI, so I would perhaps go through connecting to an RDBMS first before walking through this. It will make more sense.
    To set this up, you will need to:
    1. Copy the necessary client files from OC4J, place them in the <ODI_HOME>/oracledi/drivers directory and restart ODI. The files you need are:
    - <OC4J_HOME>/j2ee/home/oc4jclient.jar
    - <OC4J_HOME>/j2ee/home/lib/javax77.jar
    - <OC4J_HOME>/j2ee/home/lib/jta.jar
    Sop copy those files and restart ODI.
    2. Create a physical connection (Topology Application/Physical Architecture/Technologies -> right click JMS Queues and select "Insert Data Server")
    3. In the Description tab, simpl fill in the Name field.
    4. In the JNDI tab , fille in the following:
    - JNDI Authentication - Simple
    - JNDI User: application user - this is the equivalent of javax.naming.Context.SECURITY_PRINCIPAL
    - Password: application password - this is the equivalent of javax.naming.Context.SECURITY_CREDENTIALS
    - JNDI Driver: This is the equivalent of javax.naming.Context.INITIAL_CONTEXT_FACTORY, so enter com.evermind.server.rmi.RMIInitialContextFactory
    - JNDI Url: This is the equivalent of javax.naming.Context.PROVIDER_URL, so put in ormi://<hostname>[:<port>]/<application>. For instance, with the basic OC4J install, I put in ormi://localhost/default.
    - JNDI Resource: This is the JNDI lookup key for your Queue Connection factory. For example, for the default OC4J installation, I put in jms/QueueConnectionFactory
    5. Click the Test button and click OK in the window that pops up. You should get a message box saying that your connection was successful.
    6. Click Apply or OK and a new window will pop up. In this window, go to the Context tab and click the Add button and in the row that appears, click on the right most field (it says <Undefined> and replace <undefined> with a logical name for your connection. Hit Enter and click OK)
    7. You've now connected to the Queue, to create the Queue object in ODI, go to the Designer window, go to models and create a new model.
    8. Set the name to whatever makes sense to you. Set the technology to JMS Queue and the Logical Schema to the logical connection name you created in step 6. In the Reverse tab, select Global from the Context dropdown menu.
    9. Click OK. You now have a container for any Queues that are in this connection.
    10. To point to the queue, right click your new model and select Insert Datastore.
    11. In the new window, name your datastore whatever you'd like. Set the resource name to the JNDI resource name for the queue (for example, with the default OC4J configuration, you could set this to jms/demoQueue.
    12. In the Files tab, set the File Format to fixed, and set the record separator to Windows or Unix (it doesn't really matter which one you pick)
    13. In the Columns tab, click the add button to add a column. Name the column something like DATA and set is to a String of size 1000.
    14. Click OK. You'll now be able to right click this new datastore and view data, granted in a very simple format. You can create a more complex flat file structure if you' like but this gives you a quick and easy to view the contents of the queue.
    I'd suggest trying to connect this way, post if you were successful and I will then post how to connect to an XML structured queue (it's a little teenie bit different)

  • How to use ODI sequences ??

    I have an interface which need an ODI sequence.
    When I execute it the value of the sequence is always the same.
    I have seen on another thread that it may pass by an agent but...
    I have 2 tables (source and target) from the same connexion which don't and won't have agent.
    How can I do ??
    My connexion is on an Oracle 10g RDBMS and I'm using an IKM SQL Control Append.
    This is not the first time I have problem with the ODI Sequence but this time I can't create an RDBMS one ...
    Thanks in advance,
    BM

    Hi guys,
    I have some questions, I am trying to create a dimension and it should use a sequence, but I am getting the same issue as you guys. I can't not generate a unique key because my sequence is the same value for all rows.
    So if I really understood there are two ways to use a sequence in ODI. One is using ODI sequence (creating it inside ODI) and other is using a RDBMS sequence.
    First: What I have to do to use a RDBMS sequence? (Step by step please)
    Second: I can't use an IKM SQL to SQL append in my interface. This interface is pretty simple - source is a flat file target is an Oracle table, I just need to move all flat files columns to Oracle table adding a sequence. I understood that my Staging area should be different than my Target area based on posts above. I already created a new datastore to be my new staging area, but I don't know how to make an association between interface and new stage area.
    Can you please provide me the easiest solution?
    Thanks
    Leo

Maybe you are looking for

  • FBCJ Background posting

    i want to post the document using zprogram  instead of FBCJ standared program. i use one BAPI  FCJ_POST_ALL  in my report i use hot spot after clicking  on hot spot this bapi is excute  and that document is post. but it will ask me for Amount and acc

  • Integration Server URL not being updated in SXMB_ADMIN

    I have changed an incorrect entry in the SLD for my business system for my XI installation (port was wrong).  When I go into SXMB_ADMIN --> Integration Engine --> Configuration --> Integration Engine Configuration The corresponding Integration Server

  • How to get the line number of source file?

    Hi, What is the equivalent in Java of the __LINE__ and __FILE__ macros in C? I want to print out the line number and the file name where the instruction is being executed. Thanks,

  • Powershell "RunAs" causing recycle bin issues. Would like some input please.

    I developed a script to assist our UserAdmins with creation of AD user accounts and create home folders on the server shares.  I am encountering an issue with the recycle bin becoming corrupt when the user first logs in.  This script must be run with

  • Unable to install elements 9

    recently purchased an epson v500 scanner - it came with adobe photoshop elements 9 dvd - cannot get software to load - it did load the "read me " part what can i do to load the software? thanks