File to JDBC using JAVA Mapping

Hello,
  Can u explain me about the above scenario of File to JDBC using JAVA Mapping.
   Iam new to XI explain above in detail.
*Points will be Rewarded*
Thanks&Regards,
RavichandKone.

HI,
If your mapping is one to one then dont go for java mapping use graphical mapping.
/people/sap.user72/blog/2005/06/01/file-to-jdbc-adapter-using-sap-xi-30 --> for jdbc receiver: file -JDBC
Here are the link which will help you in writing the stored procedure:
Receiver JDBC scenario MS access - /people/sameer.shadab/blog/2005/10/24/connecting-to-ms-access-using-receiver-jdbc-adapter-without-dsn
Stored Procedures-
/people/siva.maranani/blog/2005/05/21/jdbc-stored-procedures
http://www.ics.com/support/docs/dx/1.5/tut6.html
/people/sriram.vasudevan3/blog/2005/02/14/calling-stored-procs-in-maxdb-using-sap-xi
http://www.ics.com/support/docs/dx/1.5/tut6.html
http://java.sun.com/docs/books/tutorial/jdbc/basics/sql.html
http://www.sqlteam.com/article/stored-procedures-an-overview
thnx
Chirag Gohil

Similar Messages

  • Dynamic file name while using java mapping

    Hi All,
    i need help.
    I am using java mapping to convert xml file in zip file.
    Now i need to set output file name as SiteId_TimeStamp.zip.
    Site id is comping in xml file.
    How can i do this?
    I tried many thing but didnt get the solution..
    As their is no message mapping so I am unable to use ASMA.
    Please help.

    Did you check the wiki? You just need to add the code into you java mapping..
      Map mapParameters = (Map) transformationInput.getInputHeader().getAll();
       // a) Set Output File name
       mapParameters.put(DynamicConfigurationKey.create("http://sap.com/xi/XI/Dynamic",
                                                             StreamTransformationConstants.DYNAMIC_CONFIGURATION), "");
       DynamicConfiguration conf = (DynamicConfiguration) mapParameters.get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
       DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File", "FileName");
       //Depending on your requirement edit this logic. Here, NewDynamicName + CurrentDate will be output file name.
       DateFormat dateFormat = new SimpleDateFormat("yyyyMMdd");
       conf.put(key, ("NewDynamicName_" + dateFormat.format(new Date())) + ".pdf");

  • Query on processing a PDF file using Java mapping

    Hi All,
    i am trying to process a XML and PDF file using Java mapping, it is successful in XML but unable to do for PDF.
    below is the code i am using... can any one guide me how to process PDF's..
    byte byte1 = 0;     
    java.io.ByteArrayOutputStream bos = (ByteArrayOutputStream)outputstream;
    while((byte1=(byte)inputstream.read())!=-1){
    bos.write(byte1);
    bos.close(); 
    Thank You,
    Madhav

    Hi Madhav,
    I think instead of going with JAVA mapping you can write a custom adapter module for it.
    Ref:  /people/sap.user72/blog/2005/07/31/xi-read-data-from-pdf-file-in-sender-adapter
    Also check : Re: PI 7.1 : Taking a input PDF file and mapping it to a hexBinary attribute
    /people/shabarish.vijayakumar/blog/2009/05/17/trouble-writing-out-a-pdf-in-xipi
    Thanks,
    Edited by: Hareenkumar on Dec 21, 2010 11:12 AM

  • N:1 Mapping Possible using Java Mapping?

    All,
    Is it possible to do a N:1 mapping using Java Mapping?
    If yes , how?
    Reason for this question is that the execute() of the Java Mapping is going to take the source / request message as the InputStream . In the case of N:1 mapping , as we have multiple messages , how will they be send to the InputStream? Will both the messages be sent combined into the InputStream? Will the MESSAGES tag be embedded into the input stream?
    Regards,
    Bhavesh

    Hi @ll;
    i try the same.
    to conduct a java mapping with 2 input structures that fills one target structure.
    This mapping is part of a Integrationprocess.
    I tested the mapping at the Integration Repository (Interface mapping) with the structure given by henrique and it works fine without any error.
    At runtime this structure looks like this (different prefix)
    <?xml version="1.0" encoding="UTF-8"?>
    <sxi:Messages xmlns:sxi="http://sap.com/xi/XI/SplitAndMerge">
         <sxi:Message1>
              <YOURXML1>...</YOURXML1>
         </sxi:Message1>
         <sxi:Message2>
              <YOURXML2>...</YOURXML2>
         </sxi:Message2>
    </sxi:Messages>
    As I put it in the Integrationprocess unfortunately a strange error arises.
    The trace Workflow-Protocoll shows following error.
    <Trace level="2" type="T">Call method execute of the application Java mapping com.endress.infoserve.xi.mapping.MergeConfigStore_IdocOrder </Trace>
    <Trace level="2" type="T">Java mapping com/endress/infoserve/xi/mapping/MergeConfigStore_IdocOrder completed. (executeStep() of com.endress.infoserve.xi.mapping.MergeConfigStore_IdocOrder </Trace>
    <Trace level="1" type="T">Parsing error after multi mapping.Expected Message<i> instead of IDOC </Trace>
    I can't make head nor tail of it.
    what´s the mistake?
    can anybody please help me?
    Thanks in advance
    Kind regards

  • 1:n Transformation using JAVA Mapping Scenario

    Hi Frnds,
    I done a scenario using 1:n Transformation Scenario using XSLT,Graphical Mapping.
    But i want to develop scenario Using JAVA Mapping.
    Can anybody done the same scenario using JAVA Mapping share the links..
    Regards,
    Raj Sekhar

    You can use SAX parser for this
    firstly create a StringBuffer sb object which will store our target output
    when startDocument() gets called append the xml declaration in this method
    sb.append("<?xml version=\"1.0\" encoding=\"utf-8\" ?>");
    sb.append("<Root>");
    next for the Test element you have your startElement() method called which will contain the name of your source tag i.e Test
    for this , you will need to set a variable boolean isTest to true which was initialised as a false value.
    in the characters method you will get the value present in this tag.
    test the variable isTest for true value.
    if it is true then append the following
    sb.append("<Test1>"name"</Test1>"); //name is the buffer passed in characters method
    sb.append("<Test2>"name"</Test2>");
    sb.append("<Test3>"name"</Test3>");
    at the end your endelement() will be called
    here reset the value of isTest to false.
    in your endDocument()
    sb.append("</Root>");
    lastly convert to byte[] and then to outputStream format
    Edited by: Progirl Progirl on Jul 4, 2008 2:00 PM

  • RFC Lookup using Java Mapping program - Examples

    Dear Experts,
    I am working on a scenario which is using 1:N mapping. For deciding the target message I have to use RFC Lookup to call the backend ERP system and there are 2 ERP systems involved in this integration. As I am using Java Mapping and never did a RFC Lookup in Java. I kindly request you to give me some examples which I could use for my RFC calls in my Java Mapping. Simple example will do.
    Client is adamant to use Java mapping, I could achieve this easily using XSLT or Graphical Mapping.
    Advance Thanks,
    Pradeep

    Hello,
    why don't you use Extended Receiver Determination Defining Extended (Dynamic) Receiver Determination - Integration Directory - SAP Library?
    What you can do is create a Message Mapping between your source message and Receivers message type. In this message mapping you can use your RFC to generate the target message.
    For example, lets say we have the function ZFM_GET_INTERFACE_INFO used to generate the List of Receivers given a source message. You could create a Message Mapping as below:
    In this case, the RFCLookup box look as below:
    The receiver determination configuration would look as follows:
    Afterwards, you will need two specific message mappings for the two ERP systems.
    Summarizing, you'll need:
    1.- A Message Mapping: Source Message to Receivers Message Type (This one uses the RFC Lookup)
    2.- A Message Mapping: Source Message to Target Message for ERP 1
    3.- A Message Mapping: Source Message to Target Message for ERP 2
    In Integration Directory you'll have 1 Receiver Determination(Source system, Target System determined Dynamically) and 2 Interface Determinations (Source System to ERP1, Source System to ERP2), etc.
    I hope you find it useful.
    Regards!

  • How TO Use Java Mapping In XI

    Hi Experts,
    please help me ,
    How TO Use Java Mapping In XI?
    Thanks
    Mahesh

    Hi,
    Just refer the following links for java mapping:-
    1./people/thorsten.nordholmsbirk/blog/2006/08/10/using-jaxp-to-both-parse-and-emit-xml-in-xi-java-mapping-programs
    2./people/alessandro.guarneri/blog/2007/03/25/xi-java-mapping-helper-dom
    Regards,
    Ashwin M
    Reward if helpful

  • XML Structure Conversion using JAVA Mapping

    Hi Experts,
    I am having a requirement in which i want to convert the contents of source xml structure into a string and map it to the target field.
    Source Structure:
    <SRC>
    <Node1>ABCD</Node>
    <Node2>XYZ</Node2>
    <Node3>1234</Node>
    </SRC>
    Target Structure:
    <TRG>
    <Node1>ABCDXYZ</Node1>
    </TRG>
    Both the source and target structures are in xml format only.....just the condition is that I have to use Java mapping to achieve it.
    The contents of Source node Node3 are not to be mapped.
    Since I have very less knowledge of Java it will be very helpful if you provide the complete code to me.
    Thanks,
    Abhishek.

    Hello Udo,
    Thank you for reply. It seems ABAP mapping is easier.
    What do you think about the idea of using Value Mapping for such conversion task? In this case is it obligatory to use Java coding? And how about performance - will it be better than in case of ABAP mapping, can you say?
    Thank you,
    Igor

  • Open a PDF file in linux using java

    Hi..
    How can I open a PDF file in linux using java.
    I am able to open PDF in windows and mac using this code
    in Windows
    Runtime.getRuntime().exec("rundll32 url.dll,FileProtocolHandler " + path_of_PDF);
    in mac
    Runtime.getRuntime().exec("open " + path_of_PDF);
    But nothing is working with linux.
    Please help
    Thanks

    One thread is enough:
    http://forum.java.sun.com/thread.jspa?threadID=5267458

  • Open PDF file in linux using java

    Hi..
    How can I open a PDF file in linux using java.
    I am able to open PDF in windows and mac using this code
    in Windows
    Runtime.getRuntime().exec("rundll32 url.dll,FileProtocolHandler " + path_of_PDF);
    in mac
    Runtime.getRuntime().exec("open " + path_of_PDF);
    But nothing is working with linux.
    Please help
    Thanks

    appi wrote:
    Hi.. I found the JDIC binary files. There are different binaries for all the plateform. Is there any solution which is independent of plateform.Yes, and we already told you: Use JDK6, which has those libraries built into the standard class library.
    How can I use these binaries in my existing project. does it work, If I place them at same place where other .class files are kept.Read the documentation of the JDIC project. I'm sure they answer this question in their FAQ.

  • Can any one please send me sample programs using java mapping..

    <b>Can any one please send me sample programs using java mapping with input and output?</b>
    please let me know how to get started with java mapping?
    Prerequisites for java mapping ?
    What are the jars need to be deployed for SAX,DOM.  And how to do it in NWDS?
    Use of Execute() and setparameter() ... StreamTransformation?
    Some sample program using java mapping with simple logic(input and output)?

    Hi,
    Did you go thro these blogs?
    /people/prasad.ulagappan2/blog/2005/06/29/java-mapping-part-i
    /people/prasad.ulagappan2/blog/2005/06/29/java-mapping-part-ii
    /people/prasad.ulagappan2/blog/2005/06/29/java-mapping-part-iii
    Nice blogs to start Java Mapping.
    Go thro this one too.
    /people/stefan.grube/blog/2006/10/23/testing-and-debugging-java-mapping-in-developer-studio
    Regards,
    P.Venkat
    Message was edited by:
            Venkataramanan

  • How to trace changes in directories and files in windows using java.

    Hi,
    Want to know how to trace changes in directories and files in windows using java.
    I need to create a java procedure that keeps track of any changes done in any directory and its files on a windows System and save this data.
    Edited by: shruti.ggn on Mar 20, 2009 1:56 AM

    chk out the bellow list,get the xml and make the procedure.....     
         Notes          
    1     Some of the similar software’s include HoneyBow, honeytrap, honeyC, captureHPC, honeymole, captureBAT, nepenthes.     
    2     Some of the other hacking software’s include keyloggers. Keyloggers are used for monitoring the keystrokes typed by the user so that we can get the info or passwords one is typing. Some of the keyloggers include remote monitoring capability, it means that we can send the remote file across the network to someone else and then we can monitor the key strokes of that remote pc. Some of the famous keyloggers include win-spy, real-spy, family keylogger and stealth spy.          
    3     Apart from theses tools mentioned above there are some more tools to include that are deepfreeze, Elcomsoft password cracking tools, Online DFS, StegAlyzer, Log analysis tools such as sawmill, etc.

  • Convert XML file into DTD using Java

    Hi All,
    I want to do convert the xml file into DTD using Java.
    I read the DOM package but didnt get clear idea.
    Anyone of you have an idea please share the coding with me.
    Any suggestions greatly appreciated.
    Thanks
    Veera

    Hi All,
    I want to do convert the xml file into DTD using Java.
    I read the DOM package but didnt get clear idea.
    Anyone of you have an idea please share the coding with me.
    Any suggestions greatly appreciated.
    Thanks
    Veera

  • How to view file from vss using java Commandline

    Hi To ALL,
    I wanted to view a file from vss through java code.
    By using the folowing code,i could able to get vss file in to local folder.
    Runtime.getRuntime().exec
    ("cmd /c ss Get $/Mywork/Myfile.java -GLC:/New");
    But i wanted to view file from vss using java code.
    any one please help me..
    Thanks in advance.........

    As always, Google is your friend.
    Follow the bouncing link.
    http://www.google.com/search?hl=en&q=VisualSourceSafe+%2B+Java+API
    PS.

  • Creating file browser GUI using java swing tree

    Hi all,
    I have some questions which i wish to clarify asap. I am working on a file browser project using java swing. I need to create 2 separate buttons. 1 of them will add a 'folder' while the other button will add a 'file' to the tree when the buttons are clicked once. The sample source code known as 'DynamicTreeDemo' which is found in the java website only has 1 add button which is not what i want. Please help if you know how the program should be written. Thx a lot.
    Regards,

    Sorry, don't know 'DynamicTreeDemo'import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import javax.swing.event.*;
    import javax.swing.tree.*;
    import java.io.File;
    public class Test extends JFrame {
      JTree jt = new JTree();
      DefaultTreeModel dtm = (DefaultTreeModel)jt.getModel();
      JButton newDir = new JButton("new Dir"), newFile = new JButton("new File");
      public Test() {
        setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        Container content = getContentPane();
        newDir.setEnabled(false);
        newFile.setEnabled(false);
        jt.setShowsRootHandles(true);
        content.add(new JScrollPane(jt), BorderLayout.CENTER);
        File c = new File("C:\\temp");
        DefaultMutableTreeNode root = new DefaultMutableTreeNode(c);
        dtm.setRoot(root);
        addChildren(root);
        jt.addTreeSelectionListener(new TreeSelectionListener() {
          public void valueChanged(TreeSelectionEvent tse) { select(tse) ; }
        JPanel jp = new JPanel();
        content.add(jp, BorderLayout.SOUTH);
        jp.add(newDir);
        jp.add(newFile);
        newDir.addActionListener(new ActionListener() {
          public void actionPerformed(ActionEvent ae) {
            TreePath tp = jt.getSelectionPath();
            if (tp!=null) {
              DefaultMutableTreeNode dmtn = (DefaultMutableTreeNode)tp.getLastPathComponent();
              File newFile = new File((File)dmtn.getUserObject(),"foo");
              if (newFile.mkdir()) {
                dmtn.add(new DefaultMutableTreeNode(newFile));
                dtm.nodeStructureChanged(dmtn);
              } else System.out.println("No Dir");
        newFile.addActionListener(new ActionListener() {
          public void actionPerformed(ActionEvent ae) {
            TreePath tp = jt.getSelectionPath();
            if (tp!=null) {
              DefaultMutableTreeNode dmtn = (DefaultMutableTreeNode)tp.getLastPathComponent();
              File newFile = new File((File)dmtn.getUserObject(),"foo.txt");
              try {
                if (newFile.createNewFile()) {
                  dmtn.add(new DefaultMutableTreeNode(newFile));
                  dtm.nodeStructureChanged(dmtn);
                } else System.out.println("No File");
              catch (java.io.IOException ioe) { ioe.printStackTrace(); }
        setSize(300, 300);
        setVisible(true);
      void select(TreeSelectionEvent tse) {
        TreePath tp = jt.getSelectionPath();
        newDir.setEnabled(false);
        newFile.setEnabled(false);
        if (tp!=null) {
          DefaultMutableTreeNode dmtn = (DefaultMutableTreeNode)tp.getLastPathComponent();
          File f = (File)dmtn.getUserObject();
          if (f.isDirectory()) {
            newDir.setEnabled(true);
            newFile.setEnabled(true);
      void addChildren(DefaultMutableTreeNode parent) {
        File parentFile = (File)parent.getUserObject();
        File[] children = parentFile.listFiles();
        for (int i=0; i<children.length; i++) {
          DefaultMutableTreeNode child = new DefaultMutableTreeNode(children);
    parent.add(child);
    if (children[i].isDirectory()) addChildren(child);
    public static void main(String[] args) { new Test(); }

Maybe you are looking for

  • After Effects CC 2014 - Rendering / saving project file to CS6

    Hello all, I'm writing here to try to understand the st**** decision to exclude mp4 and mpeg from the render possibilities from After Effects CC 2014. I would gladly go back to CS6 but as of now I have more than 40 hours of edited video project in CC

  • How to restore a table using RMAN with previous backup ?

    Hi everyone, we have to restore a table from 1 week previous backup using RMAN. Could you show me how to restore a table using RMAN with previous full backup. please Help me out. Thanks Info > oracle 10g, OS: AIX5L

  • Swap items from Sales Document to Billing Document

    Hello, I am facing with the following issue. We had customizing a Billing plan, that means that the information to make the billing document comes from the sales order. The sales document have 2 materials for sale, the first one must be delivered (it

  • Internal table problem for BDC

    Hai i am having flatfile like this format H   text1   1000   plant_name   10 short_text   X     X                                                  20 short_text   X     X                                                  30 short_text   X     X H   te

  • Guided Procedures and online interactive adobe forms.

    Hi Experts, Scenario : User have to log into GP runtime, When he clicks the first action it should display the adobe form. He  has to fill the details and submit the form. This form is routed for Approver 1 for review. The first approver will log int