Dynamic XML file names in ODI

Hi All,
Is there a way can we call the XML names dynamically.?
Here is the Scenario,
I have multiple XML files of same structure to be loaded into an Oracle table.
I have first created a XML dataserver and have given the exact path and the file name for reversing the XML model for the first time. The JDBC url was,
jdbc:snps:xml?f=/xml/file/#XML_TEST.FILE_TEST.xml&s=XML_TEST&dod=true&ro=true
After reversing i have changed the JDBC url of the XML dataserver to,
jdbc:snps:xml?f=/xml/file/#XML_TEST.var_FILE_NAME.xml&s=XML_TEST&dod=true&ro=true
I have created a variable *#XML_TEST.var_FILE_NAME* to get all the XML file names.
After that i tried to view the data from the datastores present under previously reversed XML model, but was getting the following error :
java.sql.SQLException: While generating the DTD from the XML file, a org.xml.sax.SAXParseException exception occurred saying: Document root element is missing.
Do I need to change anything in the XML model or in the Datastores?
Warm Regards,
VBV

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.

Similar Messages

  • Passing Dynamic File Name to ODI nterface for processing to another system

    Hi,
    I need help regarding passing a Dynamically Name changing fixed length Flat File in ODI Interface. This interface is built for taking the Flat File as Input and process it to SQL Server by applying Data Mapping and transformations... The input Flat File Name is sequence generated for eg: OEORD1123.txt and next file will be OEORD1124.txt and it sits in Oracle Conc tier. How to pass the latest file name to ODI interface for processing
    Regards,
    Anil..

    Hi Guys...
    I would like to suggest a way.
    a) create a single interface with dynamic resouce name (a ODI variable) with a filter to the month column like:
    month_column = '#vCountMonth'
    b) in the refresh tab of a first variable (I named "vMonth"), use the following query: (varialbe should be alphanumeric, "not persistent")
    select to_char(to_date('#vCountMonth','MM'),'month') from dual
    c) create one more ODI variable (I named "vCountMonth"), alphanumeric, not persistent and at its refresh tab write:
    select lpad(to_char(#vCountMonth + 1), 2, '0') from dual
    d) now just create a package, drag and drop the objects in the following order:
    d.1) vCountMonth in set mode and set = 0 (zero)
    d.2) vCountMonth in refresh mode
    d.3) vMonth in refresh mode
    d.4) the interface
    d.5) vCountMonth in evaluate mode, evaluating "= 12"
    ==> if NO (KO, red line) link the KO line to d.2 step
    ==> a OK line is not necessary unless you have others steps after finish the evaluating
    Make any sense? That is a single loop to have the interface developed only one time.
    Please, remember to check each thread reply as Useful or Correct if they are useful to you...

  • How can I get rid of "_data" behind xml file name

    Hello everybody,
    I use xfa.host.exportData("",0) to export xml file which I cann't appoint the name of xml. After I click the exporting button, a window jumps and fill the xml file name automatically, the name is "PDF file name_data.xml", in Adobe Reader Chinese version, "_data" will be translated by Chinese word, so it is not convenience to unify the method of getting xml.
    My problem is if I can get rid of the postfix "_data" in xml file name? I doulbt maybe I can set in LiveCycle Designer, but I can't find out at present.
    Thanks in advance!
    Enlly

    Hello radzmar
    Thank you for you soon reply!
    I learned about the function exportData(), and my form is not certified, so I use exportData("",0) to export xml file. After I click the export button, it will jump out a window to ask for selecting the path, where users want to save the xml file, and, in this window, LiveCycle will fill xml file name automatically by "xxxx_data" (xxxx is the pdf form name). I just wonder if I can avoid "_data" ?
    Do you have any idea? Thanks!

  • Dynamic Receiver file name in AS2 adapter

    Hi Experts,
    How to get dynamic receiver file name in AS2 adapter. We need receiver file name same as of sender file name.
    We tried selecting dynamic attributes file name but we are getting followin error in CC.
    Message processing failed. Cause: javax.resource.ResourceException: Fatal exception: com.seeburger.xi.connector.queue.TaskBuildException: Mandatory attribute dtAS2FileName is not present in XI message., Mandatory attribute dtAS2FileName is not present in XI message.
    Thanks,
    Hari

    hi hari,
    You can't do it manually. As both adapter are in different context.
    You can go with UDF to slove ur problem.
    Just extract the input file name using Dynamic configuration
    Store that in some variable.
    Use same name in the dynamic file name in AS2 receiver. Below code might be useful.
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create( "http://seeburger.com/xi/common/dtAS2FileName", "DYNFILENAME");
    conf.put(key,strfilename);
    Thanks
    Jai
    Edited by: Jaideep Baid on Apr 9, 2010 9:16 AM

  • Dynamic Logo file names in PO XSL-FO stylesheet

    We have different company logo files for different operating units. Hence , we require to use a dynamic logo file name in XSL-FO template.
    When I use the below for a single file it works.
         <fo:inline>
    <fo:external-graphic content-width="50pt" content-height="50pt" src="url({'${OA_MEDIA}/Logo_medium_COMCEL.jpg'})" />
    </fo:inline>
    However, I would need to make the filename dynamic.
    When a tried usng an xsl variable tos tore fielname, it didnt work.
    Any pointers as to how we can achieve that would be helpful

    Thanks for your quick reply Dave, I appreciate your time.
    But I couldn't test the new template as I was neither able to create a new PO nor was able to run the PO Output for communication Report. When I tried to create a PO the Purchase Order form did not open saying I am not setup as an employee, even the PO Output for communication did not give any LOV for the PO's.
    I tried to define employee name in the employee's login
    information (System administrator/Security/User/Define) for my user, but some how my name doesn't appear in LOV. Any help is appreciated.
    Thanks,
    Sharmila

  • Include the file dynamicly by file name

    in my jsp,I want include another jsp dynamicly
    <%@ include file="thefile.jsp" %>
    thefile.jsp should be dynamic like:
    <%=String filename=="thefile.jsp" %>
    <%@ include file=filename%>
    I know above is not working since file only take static name.
    is there any way to include the file dynamicly by file name?

    String path = "..."; // to the ressource to include
    javax.servlet.RequestDispatcher dispatcher
              = getServletContext().getRequestDispatcher(path);
    dispatcher.include(request,response);

  • Build a web gallery with amazing flash slideshows with dynamic XML files

    Build a web gallery with amazing flash slideshows with dynamic XML files
    Screenshot:
    Features
    Features
    Transitions, zooming and panning effect You can  choose from  Random, Wipe from Left, Fade to White, Cross Expansion and  other 60-plus  transition effects. Zooming and panning effect is  optional for advanced flash  templates.
    XML-driven This flash slideshow are XML-driven. The XML  document allows more personalized controls over the flash.
    Auto-playback and repeat mode The flash slideshow will play  automatically after preloading, and it can repeat playback.
    Dynamic customization Besides XML control, the  advanced  templates provide many more custom options, so that you can  create slideshow  that fits into your existing web design: width ,  height, border color,  background color, thumbnail size, etc. More about  dynamic customization
    Usage and demo visit: http://webdesigndevelopment.blog.com...swf-xml-files/

    Please excuse the bump...
    Anyone with a LR flash gallery that starts with slideshow in play mode?
    Can it even be set to do this?
    The only code in the style.xml that looks like it might be realted is line 12 <playOptions playMode="pause"/>, changing that to "play" does nothing.
    Thanks,
    Donnie

  • How to find PG.xml file name and path associated with a FUNCTION

    Hi,
    I am having a function:IRC_VIS_HOME_PAGE with Web HTML value as below:
    OA.jsp?akRegionCode=IRC_VIS_HOME_PAGE&akRegionApplicationId=800&OAPB=IRC_BRAND
    How to find PG.xml file name and path assoicated with above funtion.
    Thanks,
    ashok

    Ashok,
    Function IRC_VIS_HOME_PAGE will have 2 parameter defined for it which are OASF and OAHP where
    OASF=<SelectedFunctionName> - this tells the Framework to select this function in the given "Home Page" menu context.
    OAHP=<HomePageMenuName> - this is used ONLY with the OASF parameter, and it is used to establish the current menu context. It should point to a "Home Page" menu.
    --Shiv                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Creating dynamical flat file name in mapping?

    Hi.
    I know about the variations on how to use an input parameter and/or sysdate to create a dynamic output file name in a mapping.
    My challenge is nearly the same, but I cannot make OWB generate the correct code.
    Problem:
    - got a one column table that holds an identifier in a string field
    - got a function that reads and returns said identifier
    - imported function into OWB
    - trying to use the function call in the Flat File Operator's Target Data File Name, e.g. fixedfilename||fn_get_id()||sysdate||'.ext
    OWB creates the code:
    UTL_FILE.FOPEN(
    'my_location',
    'fixedfilename'||fn_get_id()||'_'||SYSDATE||'.ext',
    'w',
    32767
    However, when compiling the package code, it returns the warning:
    ORA-06550: PACKAGE BODY, line 2214, column 29: PLS-00201: identifier 'FN_GET_ID' must be declared
    which results in an error when trying to execute the mapping.
    I've tried substituting the function call in the FOPEN call:
    myId := fn_get_id();
    UTL_FILE.FOPEN(
    'my_location',
    'fixedfilename'||myId||'_'||SYSDATE||'.ext',
    'w',
    32767
    and this works fine, the mapping creates a file with the desired filename. But obviously not a good solution rewriting the generated code all the time....
    Anyone solved something similar?
    Could I use an input parameter and the autogenerated function GET_<PARAMETER>?
    But can I set the value of an input parameter inside the very same mapping?
    Regards,
    -Haakon-

    (It always helps writing out one's problems...)
    I managed to get it working :-)
    Added an input parameter to the mapping, and gave the outgroup variable a default value by calling my imported function.
    Then concatenated the implicitly generated function (GET_PARAMETER) in the Target Data flat file name.
    I now have a target file name that changes according to a departement id stored in a parameter table.
    Regards,
    -Haakon-

  • Dynamic attribute file name

    Hi All,
              I am trying to use dynamic attribute file name using UDF in message mapping:
    <i>String filename = null;
    filename = "Yahoo";
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key1 = DynamicConfigurationKey.create("http://seeburger.com/xi/common" , "dtSubject");
    conf.put(key1,filename);
    return "";</i>
    But its just giving me the name on the receiver side as in the sender side.
    I have checked FileName in Dynamic attributes in the reciever adapter.
    Regards,
    XIer

    your return statement looks like <i>return "";</i>
    Return the filename that you have assigned inside the UDF and can be achieved by
    conf.put(key1,filename);
    <b>return filename;</b>
    Do refer this blog as well
    /people/michal.krawczyk2/blog/2005/11/10/xi-the-same-filename-from-a-sender-to-a-receiver-file-adapter--sp14

  • 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.

  • Set xml file name

    Dear,
    I want to set the name of the xml sended by mail.
    I use a botton for this, cane help me to set the name of this file before attachement !
    Thanks

    I know that, but i need to set the xml file name sent by mail with information typed in a text field.
    For exemple un have a PDF file named : myPdf.pdf
    And each user of this pdf file will type in a text feld his name so the xml file should be named : brain.xml and not myPdf.xml
    Thanks

  • When someone other than myself downloads an image from my web album, a dynamically generated file name replaces the original file name.  How I can prevent the original file name being replaced during the downloading process?

    When someone other than myself downloads an image from my web album, a dynamically generated file name replaces the original file name.  How I can prevent the file name being changed during this downloading process?

    Hi Glenyse,
    Here are my steps.
    1.  I upload multiple image (jpg) files onto my photo album.
    2.  I select the "sharing" by email option for this album.
    3.  I enter the recipient's email address.
    4.  The recipient receives my message and clicks on the link.
    5.  The recipient accesses my photo album and clicks on one of the images.
    6.  The image opens up to its own screen.
    7.  The recipient selects the "download" and then save file option.
    Here is the part I do not understand.  For some reason, during this "download" process, the original name which I have given to the file is replaced by different name.  So I was hoping that someone knows how to prevent the file name from being changed during the "download and save" process.
    Much appreciated if you can help me find a solution to this problem.
    Mary  

  • Dynamic Configuration File Names

    Hi,
    I have a RFC->XI->File scenario.
    I have to put the target files names based on the calculation of values in 2 fields in the input.
    I tried using Dynamic Configuration in my message mapping for this.
    This is the code:
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create(u201Chttp://sap.com/xi/XI/System/Fileu201D,u201CFileNameu201D);
    String MyFileName = a + "_" + b +".xml";
    conf.put(key, myFileName);
    I checked ASMA in both the sender RFC adapter as well as the receiver file adapter.
    But it never works.
    I saw the dynamic configuration tab in SXMB_MONI but i can see only the RFC destination parameter.
    Cant see the file filename parameter.
    What is the problem here?

    No need enable ASMA on RFC sender adapter.
    See if the file channel is activated after selecting ASMA with FileName.
    The UDF might not be use in the mapping. Check this.
    Edited by: Praveen Gujjeti on Feb 23, 2010 1:05 AM

  • Dynamic flat file name as source

    Hi All,
    I working on ODI 11g 11.1.1.3 version.
    I have Flat file say ABC01 as source, flat file was successfully load into target.
    But next day new file say ABC02 with same structure was generate from client.
    Every day new file is generate say ABC03, ABC04 and so on.
    how to use this file to load data, without changing file name.
    dynamically can it is possible.
    Please give me suggestion.
    Thanks in advance
    Prashant

    Hi Prashant,
    You can achieve this by doing the following :
    1. Create a variable Called FILE_NAME
    2. Go to your file datastore and replace the Resource Name with variable #FILE_NAME. So you need to pass correct file name to the variable.
    3. To get the filename into variable , you can look into the following thread
    Read FileNames in Directory
    Hope it helps

Maybe you are looking for

  • Error while deploying ADF application to a standalone weblogic

    jdeveloper version: 11.1.2.2 Issue: I have built a standalone weblogic server (10.3.5.0) and am trying to deploy my ADF application to it. The deployment fails with the following message. The stand alone server I have built is on the same machine whe

  • How do I download app updates in the new iTunes?

    A few apps of mine have updates that are too large to download via data and wifi on my phone has been broken due to water damage. I used to just go to "Apps" in iTunes, select "Updates," download all that were available and sync the updates that way.

  • Windows (Vista) Calendar not supported for sync to iPhone?

    I am using Windows Vista Ultimate x64 and I have an iPhone 3g S 32GB and in iTunes with my iPhone selected and I am under the Info tab it will show and allow syncing contacts to Windows Contacts but the calendar section says no supported calendar can

  • Trying to view pics on a cd, message given "blank dvd"

    trying to view pics on a cd, insert cd and I am given a message of "blank dvd"  The pics were downloaded by a professional photographer

  • Any fix for the "remembering passwords" problem with MAIL?

    I've been following the other threads on this topic. I am a new Mac user (all of 5 days) with 10.5.2 preinstalled on a macbook pro, so this is not a migration problem. Applecare has been unable to resolve the issue. My setup is a Verizon FIOS POP acc