Parsing an invoice using xml

Hi,
I want to transfer a xml-file representing an invoice to Oracle Payables. This is to be done by writing a java program. I'm pretty stuck so I would appreciate any kind of help. Litterature, web-pages etc.
Regards
Ardalan

Parse xml document with the dom api.
http://java.sun.com/xml/jaxp/dist/1.1/docs/tutorial/dom/1_read.html
thanks,
Deepak

Similar Messages

  • Generate Multiple copies of same Invoice using XML Publisher

    Hello All
    I have a requirement wherein the existing XML report Output should print the same Invoice twice one orginal and one a Customer Copy.
    i.e say Earlier the Invoice was INVOICE-ABC Customer and ran into 3 pages with Page 1 of 3, Page 2 of 3, Page 3 of 3.
    Then now the requirement is to print same once more with a new Heading Invoice Copy- ABC Customer Page 1 of 3, Page 2 of 3 Page 3 of 3.
    Has any one of you faced a similar requirment.
    Suggestions/Inputs would help a lot.
    Thanks!!

    as idea
    create main concurrent and run INVOICE-ABC Customer and Invoice Copy- ABC Customer by
    fnd_request.submit_requestso if you want to use one template and changing Heading for 'COPY' then you can add parameter for invoice concurrent for identify type (copy or not)
    so in parameter not 'COPY' then Heading is 'INVOICE-ABC Customer' else 'Invoice Copy- ABC Customer'
    if you can't change template then copy and change Heading and in main run two concurrents

  • Inbound Invoice thru XML Gateway

    Hi to all,
    Thru XML Gateway i am trying to process an inbound invoice based on 171_process_invoice_002.dtd
    Invoice is matching with Receipt in our system and i dont know how to fill RECEIPT_NUMBER in invoice line (INVLINE)
    Thanks in advance
    Edited by: 980535 on 25 Απρ 2013 1:15 πμ

    Hi,
    Thru Oracle Transport Agent Send Imbound , i send an Inbound Invoice using XML
    the interface tables AP_INVOICES_INTERFACE and AP_INVOICE_LINES_INTERFACE are updated correctly and then i run the concurrent "Payable Open Interface Import"
    When the concurrent finish i receive an error "Insufficient Receipt Information" and the invoice can not be imported into AP tables
    From PO view, the PO is correct , and also there is a Receipt
    Invoice also match with Receipt , also the Supplier --> Invoices match with Receipt
    The above xml created based on 171_process_invoice_002.dtd, and i dont know how to pass the information of Receipt Number
    the above articles you mention in your post does not describe how you have to declare the element into xml file so RECEIPT_NUMBER in AP_INVOICE_LINES_INTERFACE must fill
    Thanks in advanced
    Edited by: 980535 on 25 Απρ 2013 3:52 πμ

  • A website I need to get information from returns a message stating that I do not have the most recent XML parser, and suggests using IE 5.5 or newer. This, of course, I have no intention of doing. Any suggestions?

    This is supposed to be an animated Help page. However, when Itry to click on it, it gives me the message:
    Your browser does not seem to have the most updated XML parser.
    Please use Microsoft Internet Explorer 5.5 or up for PointingTheWay features.
    System Can Not Proceed any further.

    Unfortunately, it's a member-only page, with member id and password required. I'm trying to contact their IT dept., but without much luck, so far!

  • Parse an Aggregate in XML Document using PL/SQL

    Hi. I've been successful with parsing a TAG in XML Document stored in CLOB using PL/SQL XML Parser.
    However, I need help on how to get the whole aggregate in XML Document stored in CLOB.
    sample XML Doc :
    <library>
    <book>
    <title>Oracle Complete Reference</title>
    <author>Kevin</Author>
    <year>2000</year>
    </book>
    <video>
    <title>Learning C++</title>
    <length>2 hours</length>
    <video>
    </library>
    I need a function that will accept an Input which is the aggregate name and will return the aggregate value.
    With the sample XML above, say the input is 'VIDEO', the function will return :
    <video>
    <title>Learning C++</title>
    <length>2 hours</length>
    <video>
    I'll really appreciate any help.
    null

    I used such an example to parse several Varchar2 strings in a given DB session:
    BEGIN
    parser := xmlparser.newparser ;
    xmlparser.parsebuffer(parser,xmlout) ;
    domdoc := xmlparser.getDocument(parser) ;
    xmlparser.FREEPARSER(parser) ;
    parser.id := -1 ;
    nodes := xslprocessor.selectNodes(
    xmldom.makenode(domdoc),
    'Positionen/Position') ;
    for i in 1 .. xmldom.getLength(nodes) loop
    node := xmldom.item(nodes,i-1) ;
    -- do s/thing with the node
    end loop ;
    xmldom.freedocument(domdoc) ;
    RETURN(komponenten) ;
    EXCEPTION
    WHEN OTHERS THEN
    if parser.id <> -1 then xmlparser.freeparser(parser) ;
    end if ;
    if domdoc.id <> -1 then xmldom.freedocument(domdoc) ;
    end if ;
    RAISE ;
    END ;
    However, after about 2000 of nodes lists parsed, I get an ArrayIndexOutOfBoundsException from XMLNodeCover. Obviously, I should release the nodes or the nodelist, but I have not found any procedure to do this.
    Pascal

  • Invoice Print - How to customize using XML

    We want to customize Invoice Print using XML. Currently it is in PDF format.
    When we define the data defintion, what xml schemea needs to be put for Invoice Print and where can I find the file .xsd related to Invoice Print.
    Similary we want to do it for Dunning Letters as well as Statements.
    Your help will be much appreciated.
    Regards
    Ganesan

    Hi Roy,
    That's a very good question and I have 2 options for you:
    1. Create transformer (see Transformation Service documentation to know how and there are examples) that will filter the RSS items according to content of the items. Connect this new transformer to your XML iView in the XML iView editor so it will be the first one and the built-in RSS transformer is second. SAX transformers are faster for filtering so I recommend adding this transformer. 
    2. Create your own RSS XSL transformer (again like in the documentation) that will filter the items and create the UI.
    I hope this will help you.
    Elisha

  • How can (parse) i use XML file with missing EndTag

    hi,
    i have an application which writes an "XML file".
    another application should read that XML file, build an DOM and
    access the nodes with xpath.
    my problem. if the first application is not finished there are tags
    missing. e.g. </xml>. but the seconds application cannot wait until the first application finishes it task.
    if i now read the XML file the parser cannot load it because the end tags are missing.
    my question:
    how can i deactivate the check or how can i read the XML file and access it via XPath (my application is using at the moment XPath to access the nodes and i dont want to change that)
    as parser i am using XERCES
    alex

    As far as I know, you can't do this - xml must be well formed (this is sort of a bedrock of xml). There may be some work around's, but I'm not aware of any - and they would most likely be hacks.

  • HO w to use SAX parser to create an XML file on the fly

    Hi All,
    Currently I am using the DOM parser to create an XML file from a text file. But as the DOM takes much memory and inefficient, I need to convert the DOM translator to SAX translator. Can I do that ?? If YES then how to go about that and if NO then what may be the workaround for that.
    Please help me out
    Thanx in advance
    kaushik

    Incidentally, look at this thread:
    http://forum.java.sun.com/thread.jsp?forum=34&thread=252415
    It has an example of how to transform an XML file via XSLT. If you change this to use the zero-argument form of newTransformer, it will apply the "identity transformation" to your input, thus outputting your XML in valid form. Now you just need to figure out how to provide SAX input to this, and the JAXP download includes an example of that.

  • Using XML DB to parse xmls

    Can i use XML DB to parse the XMLs and store their content in corresponding columns in the database table.If yes it would be helpful if i can have a look at some example besides this is it efficient to use xml db for this purpose.

    Hi,
    This is a good place to look [XML DB FAQ|http://forums.oracle.com/forums/ann.jspa?annID=278]
    Regards
    Peter

  • Trying to use XML SAX parser with JDK2 ...

    Hi,
    I'm pretty new to Java.
    I'm trying to write and use java sample using XML SAX parser. I try with XP and XML4J.
    Each time I compile it give me a error message like
    "SAX01.java:23: unreported exception java.lang.Exception; must be caught or declared to be
    thrown
    (new SAX01()).countBooks();
    ^
    Note: SAX01.java uses or overrides a deprecated API.
    Note: Recompile with -deprecation for details.
    1 error"
    For what I found, it seems that "deprecated" mean usage of old classes or methods. What should I do ?
    Wait for the XML parser to be rewrite ? ....
    Thank's
    Constant

    "SAX01.java:23: unreported exception
    java.lang.Exception; must be caught or declared to be
    thrown
    (new SAX01()).countBooks();
    ^Do this
    public static void main(String[] args) throws Exception {
    or do this
         try
                       first part of expression?(new SAX0()).countBooks();
         catch(Exception ex)     
              System.out.println("problem "+ ex);
    Note: SAX01.java uses or overrides a deprecated API.
    Note: Recompile with -deprecation for details.
    1 error"deprecation is just a warning if there are no errors elsewhere in your program it should compile fine, but if you want to find out how to change it do this:
    javac YourClassName.java -deprecation
    then look in the docs for an alternative.

  • Getting the following error while parsing the values usng xml parser

    Hi
    I am getting the following error while parsing the values using the code in r12 instance on linux
    declare
    XML_PARSER XMLPARSER.PARSER;
    DOC XMLDOM.DOMDOCUMENT;
    DOCELEMENT DBMS_XMLDOM.DOMELEMENT;
    BEGIN
    -- NEW PARSER
    XML_PARSER := XMLPARSER.NEWPARSER;
    -- SET SOME CHARACTERISTICS
    XMLPARSER.SETVALIDATIONMODE(XML_PARSER, FALSE);
         IF P_DIR IS NOT NULL AND P_FILENAME IS NOT NULL
         THEN
         FND_FILE.PUT_LINE(FND_FILE.LOG,'DIRECTORY FOUND'||'-'||P_DIR);
         XMLPARSER.SETBASEDIR(XML_PARSER, P_DIR);     
         -- PARSE INPUT FILE
         FND_FILE.PUT_LINE(FND_FILE.LOG,'FILE FOUND'||'-'||P_FILENAME);
         XMLPARSER.PARSE(XML_PARSER, P_DIR || '/' || P_FILENAME);     
         -- GET DOCUMENT
         DOC := XMLPARSER.GETDOCUMENT(XML_PARSER);
         LOAD_SUPP(doc);
         ELSE
         DBMS_OUTPUT.PUT_LINE('DIRACTORY/FILENAME CANNOT BE NULL');
         END IF;
    EXCEPTION
    WHEN OTHERS THEN
    DBMS_OUTPUT.PUT_LINE('DATA NOTINSERTED'||sqlerrm);
         ROLLBACK;
    END
    I am getting the following error
    DIRACTORYL-/home/appldevORA-0000: normal, successful completion
    FILE NAME-suppliersample_data.xmlORA-0000: normal, successful completion
    DATA NOTINSERTEDORA-31001: Invalid resource handle or path name "/home/appldev/suppliersample_data.xml"
    ORA-06512: at "SYS.XDBURITYPE", line 11
    ORA-06512: at "XDB.DBMS_XSLPROCESSOR", line 142
    ORA-29280: invalid directory path
    ORA-29280: invalid directory path
    ORA-29280: invalid directory path
    It could be great if some one could give a suggestion/solution.
    Thanks
    Ajesh

    Besides this is not the correct forum try to google the error message first before posting:
    http://ora-29280.ora-code.com/
    cheers

  • How to write a procedure to load the data into a table using xml file as input to the procedure?

    Hi,
    Iam new to the xml,
    can u please anyone help me how to write procedure to load the data into a table using xml as input parameter to a procedure and xml file is as shown below which is input to me.
    <?xml version="1.0"?>
    <DiseaseCodes>
    <Entity><dcode>0</dcode><ddesc>(I87)Other disorders of veins - postphlebitic syndrome</ddesc><claimid>34543></claimid><reauthflag>0</reauthflag></Entity>
    <Entity><dcode>0</dcode><ddesc>(J04)Acute laryngitis and tracheitis</ddesc><claimid>34543></claimid><reauthflag>0</reauthflag></Entity>
    <Entity><dcode>0</dcode><ddesc>(J17*)Pneumonia in other diseases - whooping cough</ddesc><claimid>34543></claimid><reauthflag>0</reauthflag></Entity>
    </DiseaseCodes>.
    Regards,
    vikram.

    here is the your XML parse in 11g :
    select *
      from xmltable('//Entity' passing xmltype
    '<?xml version="1.0"?>
    <DiseaseCodes>
    <Entity><dcode>0</dcode><ddesc>(I87)Other disorders of veins - postphlebitic syndrome</ddesc><claimid>34543></claimid><reauthflag>0</reauthflag></Entity>
    <Entity><dcode>0</dcode><ddesc>(J04)Acute laryngitis and tracheitis</ddesc><claimid>34543></claimid><reauthflag>0</reauthflag></Entity>
    <Entity><dcode>0</dcode><ddesc>(J17*)Pneumonia in other diseases - whooping cough</ddesc><claimid>34543></claimid><reauthflag>0</reauthflag></Entity>
    </DiseaseCodes>
    ') columns
      "dcode" varchar2(4000) path '/Entity/dcode',
      "ddesc" varchar2(4000) path '/Entity/ddesc',
      "reauthflag" varchar2(4000) path '/Entity/reauthflag'
    dcode                                                                            ddesc                                                                            reauthflag
    0                                                                                (I87)Other disorders of veins - postphlebitic syndrome                           0
    0                                                                                (J04)Acute laryngitis and tracheitis                                             0
    0                                                                                (J17*)Pneumonia in other diseases - whooping cough                               0
    SQL>
    Using this parser you can create procedure as
    SQL> create or replace procedure myXMLParse(x clob) as
      2  begin
      3    insert into MyXmlTable
      4      select *
      5        from xmltable('//Entity' passing xmltype(x) columns "dcode"
      6                      varchar2(4000) path '/Entity/dcode',
      7                      "ddesc" varchar2(4000) path '/Entity/ddesc',
      8                      "reauthflag" varchar2(4000) path '/Entity/reauthflag');
      9    commit;
    10  end;
    11 
    12  /
    Procedure created
    SQL>
    SQL>
    SQL> exec myXMLParse('<?xml version="1.0"?><DiseaseCodes><Entity><dcode>0</dcode><ddesc>(I87)Other disorders of veins - postphlebitic syndrome</ddesc><claimid>34543></claimid><reauthflag>0</reauthflag></Entity><Entity><dcode>0</dcode><ddesc>(J04)Acute laryngitis and tracheitis</ddesc><claimid>34543></claimid><reauthflag>0</reauthflag></Entity><Entity><dcode>0</dcode><ddesc>(J17*)Pneumonia in other diseases - whooping cough</ddesc><claimid>34543></claimid><reauthflag>0</reauthflag></Entity></DiseaseCodes>');
    PL/SQL procedure successfully completed
    SQL> select * from MYXMLTABLE;
    dcode                                                                            ddesc                                                                            reauthflag
    0                                                                                (I87)Other disorders of veins - postphlebitic syndrome                           0
    0                                                                                (J04)Acute laryngitis and tracheitis                                             0
    0                                                                                (J17*)Pneumonia in other diseases - whooping cough                               0
    SQL>
    SQL>
    Ramin Hashimzade

  • Using XML-based object structures to represent data in code/at run-time

    Hello,
    I have quite a "high level" question which has be bothering me for some time, and I haven't found the subject tackled in any books. I believe J2SE/J2EE is not an important divide here.
    Lets say I want to develop a J2SE game application with two programs: a "level designer", and a "level viewer", and I want to store the level files in an XML format.
    My question, and I use this example only to try and illustrate it, is:
    when coding the level designer or viewer, is it reasonable to use an XML-based object hierarchy for representing a level in code/at run-time, i.e. using the standard Java DOM APIs? Or should one (as I would have done before XML came along) develop a set of classes much closer to modelling the real form of a level, and then add a means to convert those objects to/from to XML format?
    This second option of course I would use/would have used if I wasn't thinking about XML, but isn't it sometimes easier to just read in an XML file into a DOM representation and just use the data straight out of that structure, rather than go through the bother of parsing the XML into a set of unrelated objects defined by a different family of classes? What shapes your decision here? And if the second option is best, what is the easiest way of converting to/from the XML?
    Thank you for any advice.
    Greg

    Hi Christian,
    Can I ask: what about if your domain was quite 'close' to an object/DOM representation of XML?
    For instance, what if a game operated by acting out a theatrical script, a spoken conversation, between two characters, perhaps somehow influenced at points by the user, and a particular level was just a different script for the characters.
    One could imagine that the object representation of this would in the end be quite similar to how you'd represent XML, i.e. like a tree of nodes, where each node was a line from the script, and some nodes were a decision point where different nodes could be chosen from.
    Would you still want to avoid using XML-based classes to represent the underlying 'game', or is there a point where you would 'give it' to the similarity and use existing XML structures directly?
    Thank you for any advice
    Greg

  • Getting error while running the XML file using XML Publisher Desktop

    Hi all,
    We have successfully loaded the XML file using XML Publisher Desktop. But when we preview the same using PDF format we are getting the following error.
    Font Dir: C:\Program Files\Oracle\XML Publisher Desktop\Template Builder for Word\fonts
    Run XDO Start
    RTFProcessor setLocale: en-us
    FOProcessor setData: C:\Documents and Settings\smanmadh\Desktop\ProductCompensationDT.xml
    FOProcessor setLocale: en-us
    java.lang.NullPointerException
         at oracle.apps.xdo.template.fo.area.PageNumber.formatString(PageNumber.java:104)
         at oracle.apps.xdo.template.fo.IDManager.registerId(IDManager.java:44)
         at oracle.apps.xdo.template.fo.area.AreaTree.registerLastPageJoinSeq(AreaTree.java:1106)
         at oracle.apps.xdo.template.fo.area.AreaTree.incrementJoinSequenceIndex(AreaTree.java:219)
         at oracle.apps.xdo.template.fo.area.AreaTree.registerLastPageDocument(AreaTree.java:1089)
         at oracle.apps.xdo.template.fo.area.AreaTree.forceOutput(AreaTree.java:471)
         at oracle.apps.xdo.template.fo.elements.FORoot.end(FORoot.java:58)
         at oracle.apps.xdo.template.fo.FOHandler.endElement(FOHandler.java:386)
         at oracle.xml.parser.v2.XMLContentHandler.endElement(XMLContentHandler.java:196)
         at oracle.xml.parser.v2.NonValidatingParser.parseElement(NonValidatingParser.java:1212)
         at oracle.xml.parser.v2.NonValidatingParser.parseRootElement(NonValidatingParser.java:301)
         at oracle.xml.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:268)
         at oracle.xml.parser.v2.XMLParser.parse(XMLParser.java:149)
         at oracle.apps.xdo.template.fo.FOProcessingEngine.process(FOProcessingEngine.java:279)
         at oracle.apps.xdo.template.FOProcessor.generate(FOProcessor.java:1022)
         at RTF2PDF.runRTFto(RTF2PDF.java:626)
         at RTF2PDF.runXDO(RTF2PDF.java:460)
         at RTF2PDF.main(RTF2PDF.java:251)
    Thanks in Advance.
    Sudeep.

    This is BI related. You will get a quicker answer from the BI Publisher forum
    BI Publisher

  • Error while running the XML file using XML Publisher Desktop

    Hi All,
    We have successfully loaded the XML file using XML Publisher Desktop.But when we try to preview it using the PDF format we are getting the following error.
    Font Dir: C:\Program Files\Oracle\XML Publisher Desktop\Template Builder for Word\fonts
    Run XDO Start
    RTFProcessor setLocale: en-us
    FOProcessor setData: C:\Documents and Settings\smanmadh\Desktop\ProductCompensationDT.xml
    FOProcessor setLocale: en-us
    java.lang.NullPointerException
         at oracle.apps.xdo.template.fo.area.PageNumber.formatString(PageNumber.java:104)
         at oracle.apps.xdo.template.fo.IDManager.registerId(IDManager.java:44)
         at oracle.apps.xdo.template.fo.area.AreaTree.registerLastPageJoinSeq(AreaTree.java:1106)
         at oracle.apps.xdo.template.fo.area.AreaTree.incrementJoinSequenceIndex(AreaTree.java:219)
         at oracle.apps.xdo.template.fo.area.AreaTree.registerLastPageDocument(AreaTree.java:1089)
         at oracle.apps.xdo.template.fo.area.AreaTree.forceOutput(AreaTree.java:471)
         at oracle.apps.xdo.template.fo.elements.FORoot.end(FORoot.java:58)
         at oracle.apps.xdo.template.fo.FOHandler.endElement(FOHandler.java:386)
         at oracle.xml.parser.v2.XMLContentHandler.endElement(XMLContentHandler.java:196)
         at oracle.xml.parser.v2.NonValidatingParser.parseElement(NonValidatingParser.java:1212)
         at oracle.xml.parser.v2.NonValidatingParser.parseRootElement(NonValidatingParser.java:301)
         at oracle.xml.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:268)
         at oracle.xml.parser.v2.XMLParser.parse(XMLParser.java:149)
         at oracle.apps.xdo.template.fo.FOProcessingEngine.process(FOProcessingEngine.java:279)
         at oracle.apps.xdo.template.FOProcessor.generate(FOProcessor.java:1022)
         at RTF2PDF.runRTFto(RTF2PDF.java:626)
         at RTF2PDF.runXDO(RTF2PDF.java:460)
         at RTF2PDF.main(RTF2PDF.java:251)
    Any pointers will be of great help.
    Thanks in Advance
    Sudeep.


    I had a similar error which when I searched, came up with this thread.
    My issue was resolved after I discovered that my RTF template was not really RTF. It was sill in MS Word DOC format. This was discovered by reviewing two templates in NOTEPAD. The MS-DOC files have a lot of "special" characters in them. My RTF was not really RTF.
    After doing a SAVE AS - RTF format, then the preview worked as expected.
    Just Sharing...
    --Tim                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

Maybe you are looking for

  • GRC-NFe - Erro de assinatura de notas

    Amigos, Estou com o seguinte problema. A nota fiscal sai do ERP e chega no GRC, ficando com o seguinte status: status de erro = 20 Serviço de assinatura digital não acessível. Ao reinicializar a nota pelo o GRC está aparecendo a mensagem Erro na cham

  • Error in native code while using JMF player

    I have written the following test program: import java.io.File; import java.io.IOException; import javax.media.Time; import javax.media.Player; import javax.media.Manager; import javax.media.NoPlayerException; class MyMP3Player { public static void m

  • Problems moving distribution from one environment toanother

    Hi all, Problems moving distribution from one environment to another Initially we have the environment as below:- Production :- Server1 : AIX Environment manager (dealing with conductor, web, db) Server2 : NT Node manager (dealing with outlook) Devel

  • OBE-15065: Syntax error query builder

    Hello i am using the below sql query. SELECT ( A.emp || '200' || LPAD((SELECT COUNT(*) FROM TRANSACTIONS WHERE TRANSACTIONS.PROCESSED ='N'),6,'0') || LPAD((SELECT SUM(AMOUNT) FROM TRANSACTIONS WHERE TRANSACTIONS.PROCESSED ='N'),10,'0') || '0000000000

  • PDF prints with little boxes and question marks

    I prepared a document in Microsoft Publisher 360 and created a pdf with creative cloud. Looks great and prints great for me. I emailed it to a few people and it looks great on their screens. However, when they print it, it comes out with little boxes