Updating 3rd parties db table using JDBC adapter at sender side

hi all.
i just want to know how i can updated the 3rd party db table field.
my scenario is just to retrieve data from 3rd party DB table where the condition is like " to select records where processed (field name ) = " ".
but i just need to update this field to x immediately after retrieving data from it.
so i simply wote the sql statement select REC_NO, ACTN_DAT, METRNO, MET-READ from PHAKAMA_CONN where processed = " ". under jdbc CC query sql stmt  at sender side .
but i want to know how we can updated the processed (field ) from " " to "x"immeidtely after retrieving.
so could any body advice me how we can achiev this through UPDATE SQL STMT under sender jdbc cc.i just want to know wat stmt do we need to srite under this.
waiting for u r response.
cheers.
seeta ram.

Ram,
Execute your Select statement as needed and in the sender jdbc communication channel in the update SQL statement give this:
UPDATE <tablename> SET <fieldname> = 'X' WHERE <fieldname>= ' '
Also just to make sure if you have access to the database just login and execute this statement which should give the results as expected. If this works here successfully then it executes the same in XI also.
Regards,
---Satish

Similar Messages

  • Can we use JDBC adapter at ECC side to extract the data directly

    Hi ,
    Is it possible in any way we can use JDBC adapter at SAP to extract data from sap tables.because as far as i know jdbc adapter used only when we having some database system at sender side.
    Regards

    Hi,
    SAP R3 is installed over a DB (Oracle, DB2 etc) this DB as a persistent storage for storing data and other information. R3 rovides a layer over the underlying database so that no one can directly access or modify the contents (due to security and data integrity issues). Hence it exposes its own RFC's for data access and modifications...
    But like I said before SAP recommends to make use of RFC's or BAPI's to access data stored in R3 tables; but we can also access them directly.You need to take the help of a DB admin for this
    Regards
    Suraj

  • Updating multiple tables using JDBC Adapter

    Hi,
    I am trying to insert/update multiple tables using one message via JDBC adapter. The following is the message being posted. However, only the first statement was executed. Anything wrong?
    Thanks in advance!
    Hart
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:DeliveryDBUpdate xmlns:ns0="http://test.com/r3_integration"><DeliveryData><DelHeader action="UPDATE_INSERT"><table>DelHeader</table><access><DelNo>0080000230</DelNo><DelType>LF</DelType><XOverwrite>X</XOverwrite><ShipTo>0000000026</ShipTo><SoldTo>0000000026</SoldTo><Priority>00</Priority><DocDate>02/17/2007</DocDate><GText>CIF Test</GText><DelDate>02/20/2007</DelDate><PickDate>02/20/2007</PickDate><ShipPoint>NO02</ShipPoint><PackCount>00000</PackCount></access><key><DelNo>0080000230</DelNo></key></DelHeader>
    <DelItem action="INSERT"><table>DelItem</table><access><DelNo>0080000230</DelNo><ItemNo>000010</ItemNo><GText>10# GRAN-GREAT VALUE</GText><Material>G04410G611</Material><Plant>6005</Plant><SLoc>6005</SLoc><RefDoc>mmenon32</RefDoc><RefItem>00000000</RefItem><DelQty>5.000</DelQty><UOM>BL</UOM></access><access><DelNo>0080000230</DelNo><ItemNo>000020</ItemNo><GText>25# GRAN- GREAT VALUE</GText><Material>G04025G611</Material><Plant>6005</Plant><SLoc>6005</SLoc><RefDoc>mmenon32</RefDoc><RefItem>00000000</RefItem><DelQty>5.000</DelQty><UOM>BG</UOM></access></DelItem></DeliveryData></ns0:DeliveryDBUpdate>

    Hi,
    You need 2 STATEMENT level tags,
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:DeliveryDBUpdate xmlns:ns0="http://test.com/r3_integration">
    <b><DeliveryData1></b>
    <DelHeader action="UPDATE_INSERT">
    <table>DelHeader</table>
    <access>
    <DelNo>0080000230</DelNo>
    <DelType>LF</DelType>
    <XOverwrite>X</XOverwrite>
    <ShipTo>0000000026</ShipTo>
    <SoldTo>0000000026</SoldTo>
    <Priority>00</Priority>
    <DocDate>02/17/2007</DocDate>
    <GText>CIF est</GText>
    <DelDate>02/20/2007</DelDate>
    <PickDate>02/20/2007</PickDate>
    <ShipPoint>NO02</ShipPoint>
    <PackCount>00000</PackCount>
    </access>
    <key>
    <DelNo>0080000230</DelNo>
    </key>
    </DelHeader>
    <b><DeliveryData1></b>
    <b><DeliveryData2></b>
    <DelItem action="INSERT">
    <table>DelItem</table>
    <access>
    <DelNo>0080000230</DelNo>
    <ItemNo>000010</ItemNo>
    <GText>10# GRAN-GREAT VALUE</GText>
    <Material>G04410G611</Material>
    <Plant>6005</Plant>
    <SLoc>6005</SLoc>
    <RefDoc>mmenon32</RefDoc>
    <RefItem>00000000</RefItem>
    <DelQty>5.000</DelQty>
    <UOM>BL</UOM>
    </access>
    <access>
    <DelNo>0080000230</DelNo>
    <ItemNo>000020</ItemNo>
    <GText>25# GRAN- GREAT VALUE</GText>
    <Material>G04025G611</Material>
    <Plant>6005</Plant>
    <SLoc>6005</SLoc>
    <RefDoc>mmenon32</RefDoc>
    <RefItem>00000000</RefItem>
    <DelQty>5.000</DelQty>
    <UOM>BG</UOM>
    </access>
    </DelItem>
    <b></DeliveryData2></b>
    </ns0:DeliveryDBUpdate>
    Try with such a strcuture and let us know if it works.
    Regards
    Bhavesh

  • Populating SAP Database table using JDBC adapter

    Hi Folks,
        I have a requirement to populate a SAP database table say ZTABLE using XI. The Model is the table has to be populated through a file which will be processed by SAP XI. Basically this is a File to JDBC scenario. The database used is ORACLE. Kindly provide me some idea to go ahead.

    I tried to place the MS access table in the shared folder of the Application server system but still it seems the table is not being populated.
    did you check the log in your receiver channel? (/people/sameer.shadab/blog/2005/10/24/connecting-to-ms-access-using-receiver-jdbc-adapter-without-dsn)
    The requirement is to update the tables directly as those are the custom tables.
    i would still say that do not update SAP tables directly from XI/ PI.....this is not a standard architecture/ solution....

  • Inserting Multiple Rows into Database Table using JDBC Adapter - Efficiency

    I need to insert multiple rows into a database table using the JDBC adapter (receiver).
    I understand the traditional way of repeating the statement multiple times, each having its <access> element. However, I am just wondering whether this might be performance-inefficient, as it might insert records one by one.
    Is there a way to ensure that the records are inserted into the table as a block, rather than record-by-record?

    Hi Bhavesh/Kanwaljit,
    If we have multiple ACCESS tags then what happens is that the connection to the database is made only once. But the data is inserted row by row.
    Why i am saying this?
    If we add the following in JDBC Adapter..logSQLStatement = true. Then incase of multiple inserts we can see that there are multiple
    <i>Insert into tablename(EMP_NAME,EMP_ID) VALUES('J','1000')
    Insert into tablename(EMP_NAME,EMP_ID) VALUES('J','2000')</i>
    Doesnt this mean that rows are inserted one by one?
    Correct me if i am wrong.
    This does not mean that the transaction is not guaranted. Either all the rows will be inserted or rolled back.
    Regards,
    Sumit

  • Same file name using JMS adapter on sender side.

    Hi Friends,
    I got a requirement to capture file name using JMS adapter on the sender side.
    Can some one help me in resolving this issue.
    Regards,
    Jeevan.

    Hi ,
    You can use Dynamic Configuration in mapping.
    Create a UDF with input as file name and copy/paste this code
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    //conf.removeAll();
    DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","FileName");
    //String filename= conf.get(key);
    conf.put(key, fileName);
    key= null;
    return fileName;
    Thanks.

  • Unable to update SQL Server thru XI using JDBC Adapter

    Hi,
    I am trying to update SQL Server. When I run the scenario I get Success status in sxmb_moni, But when I see in SQL server nothing is getting updated. Can anybody let me know where I may be doing wrong?
    Thanks In Advance.
    Yaseen.

    Hi Yaseen,
    Just go through this link, to see how to install the JDBC drivers,
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/3867a582-0401-0010-6cbf-9644e49f1a10
    Regards,
    Bhavesh

  • Http adapter at sender side for synchronous interface

    Hi SapAll.
    here for one synchronous interface we using http adapter at sender side.
    i just want to know on how i can get the sender ip adress or url through which they sending the data.
    will be waiting for best asnwer.
    regards.
    Varma

    Http adapter at sender side for synchronous interface
    i cont see any messages in xi producction.
    Is LOGGING_SYNC enabled for your production box....also is the problem just about the visibility of the messages or is your scenario itself not getting executed?
    At least the sender application might have received some error response if posting message to XI was a failure....also if possible check the message monitoring in RWB if you feel an error has occured.
    Regards,
    Abhishek.

  • How to handle the BOLB column Using JDBC adapter

    Hi,
      I want to sending of a BOLB column from a DB2 database table to another DB2 database, and the sender and receiver both by using JDBC adapter. The two tables in each other database have the same columns.
      Here is the table's structure:
      <ID>string type</ID>
      <PDF>blob type</PDF>
      Also, i haved create two DataTypes in PI system.
      Sender DataType:
      ns:DT_PDF_Req xmlns:ns="http://XXXXX.com/sap/xi">
       <row>
         <ID>1</ID>
         <PDF></PDF>
       </row>
      </ns:DT_PDF_Req>
      Receiver DataType:
      <ns0:DT_PDF_Res xmlns:ns0="http://XXXX.com/sap/xi">
      <STMT>
      <dbtable action="INSERT">
      <table>tablename</table>
      <access>
       <ID></ID>
       <PDF></PDF>
      </access>
      </dbtable>
      </STMT>
      </ns0:DT_PDF_Res>
    When test this interface, i found the that we can get the data, but when execute the insert stms  the follow errors occured  in RWB :
    <ERROR>
    Could not execute statement for table/stored proc. "DBDPUSER.pdf" (structure "STMT") due to com.ibm.db2.jcc.b.nm: DB2 SQL Error: SQLCODE=-103, SQLSTATE=42604, SQLERRMC=255044462d312e330a25c7ec8fa20a352030206f626a0a3c3c2f4c656e677468203620, DRIVER=3.50.153
    JDBC Message processing failed, due to Error processing request in sax parser: Error when executing statement for table/stored proc. 'DBDPUSER.pdf' (structure 'STMT'): com.ibm.db2.jcc.b.nm: DB2 SQL Error: SQLCODE=-103, SQLSTATE=42604, SQLERRMC=255044462d312e330a25c7ec8fa20a352030206f626a0a3c3c2f4c656e677468203620, DRIVER=3.50.153
    </ERROR>
    Can anybody tell me how to resolve the problems?
    And tell me about how to deal BOLB column using PI.
    Best Regards
    Terry

    Hi Terry Qin,
    I understand, you are getting below XML from sender JDBC channel. But when you getting SAX parser error, in receiver JDBC.
    <ns:DT_PDF_Req xmlns:ns="http://XXXXX.com/sap/xi">
    <row>
    <ID>1</ID>
    <PDF></PDF>
    </row>
    </ns:DT_PDF_Req>
    I think it is because the XML which is going to receiver JDBC channel is not well formed (because pdf can containg < & characters).
    You can achive this sceanrio, by selecting receiver JDBC channel as Message Protocol "Native SQL Format" [Link1|http://help.sap.com/saphelp_nwpi711/helpdata/en/44/7c24a75cf83672e10000000a114a6b/frameset.htm] you can send non XML to receiver channel.
    Before that, you have convert above input XML into SQL statement, using Java Mapping.
    Regards,
    Raghu_Vamsee

  • NCHAR issue with oracle database using JDBC adapter

    Hi,
    We have a requirement to develop an XI interface from FTP server(File adapter) to oracle database using JDBC adapter. In the oracle database table few fields are of type NCHAR/NVARCHAR. when we try to insert the character(A,B,c..) values into oracle table fields of type NCHAR/NVARCHAR, we are getting the following error message in the JDBC adapter audit log. IF we pass the numeric value to the same field, then we are able to insert the records successfully.
    Unable to execute statement for table or stored procedure. 'IPCSDD_DOWNLOAD_PROCESS' (Structure 'StatementName1') due to java.sql.SQLException: ORA-00904: "P": invalid identifier
    2010-10-19 22:29:59 Error JDBC message processing failed; reason Error processing request in sax parser: Error when executing statement for table/stored proc. 'IPCSDD_DOWNLOAD_PROCESS' (structure 'StatementName1'): java.sql.SQLException: ORA-00904: "P": invalid identifier
    2010-10-19 22:29:59 Error MP: Exception caught with cause com.sap.aii.af.ra.ms.api.RecoverableException: Error processing request in sax parser: Error when executing statement for table/stored proc. 'IPCSDD_DOWNLOAD_PROCESS' (structure 'StatementName1'): java.sql.SQLException: ORA-00904: "P": invalid identifier
    Please find the system information below.
    Oracle version- 10.2.4
    XI version - 3.0/ service pack 19
    JDBC driver- oracle.jdbc.driver.OracleDriver
    Please suggest.
    Thanks,
    Venkata
    Edited by: Venkata Narayana  Eepuri on Oct 21, 2010 12:10 AM

    Dear Venkata Narayana,
    Concerning the error, kindly go through the following note :
    731 - Collective note: ORA-00904
    follow the recommendations mentioned in that and please check if that helps.
    Best Regards
    Nishwanth

  • Using JDBC Adapter posting data from Oracle database to Falt file????

    Hi All,
      By using JDBC adapter, for now I have to connect to Oracle Database and then get the employee information from the Employee Table and post it to the flat file, can you please help me out the complete procedure...
    Thanks in advance
    Andy

    Hi Andy,
    have a look at the help for configuring a JDBC Sender adapter: http://help.sap.com/saphelp_nw04/helpdata/en/7e/5df96381ec72468a00815dd80f8b63/content.htm
    It mentions all the settings you'll need to make e.g. the connection URL as posted above.
    And it also lists how an XML file looks like that contains the query results according to the SQL Select statement in the adapter.
    <resultset>
    <row>
    <column-name1>column-value</ column-name1>
    <column-name2>column-value</ column-name2>
    <column-name3>column-value</ column-name3>
    </row>
    <row>
    <column-name1>column-value</ column-name1>
    <column-name2>column-value</ column-name2>
    <column-name3>column-value</ column-name3>
    </row>
    </resultset>
    So you have to create a datatype, message type and message interface to match this structure (of course you'll need to substitute column-name1 etc. with the column names in your select statement).
    Now if you want to create a flat file from that, you have to create an XML representation of that flat file and use the content conversion in the receiver file adapter as defined here: http://help.sap.com/saphelp_nw04/helpdata/en/d2/bab440c97f3716e10000000a155106/content.htm
    Regards
    Christine

  • Quering MySql DB tables using DB adapter in Oracle SOA

    Hi',
    I am trying to query MySql DB tables using DB adapter in Oracle SOA.
    inside the weblogic server console I have created a data source and test is "success" MySql
    Now inside the deployments > DBAdapter > Configuration > outbound connection pools
    I am new outbound connection, however I only get one option by default "javax.resource.cci.ConnectionFactory".
    which is default pointing to oracle DB.
    If someone has implemented this earlier or some blog/document demonstrates this please let me know.
    Thanks
    Yatan

    Thanks Naresh,
    actually I tried changing the "platformClassName" to "oracle.toplink.platform.database.MySQL4Platform" in the existing connection factory.
    I am able to update the DBAdapter successfully, however when I try to run the service created in JDEV which uses this MySql DB table it gives me below error.
    I also have another doubt regarding "How can we create a new connection factory in weblogic console?"
    ERROR:
    The selected operation process could not be invoked.
    An exception occured while invoking the webservice operation. Please see logs for more details.
    oracle.sysman.emSDK.webservices.wsdlapi.SoapTestException: Exception occured when binding was invoked.
    Exception occured during invocation of JCA binding: "JCA Binding execute of Reference operation 'insert' failed due to: Could not create/access the TopLink Session.
    This session is used to connect to the datastore.
    Caused by Exception [EclipseLink-7042] (Eclipse Persistence Services - 2.1.3.v20110304-r9073): org.eclipse.persistence.exceptions.ValidationException
    *Exception Description: Database platform class [org.eclipse.persistence.platform.database.MySQL4Platform] not found.*
    Internal Exception: Exception [EclipseLink-3007] (Eclipse Persistence Services - 2.1.3.v20110304-r9073): org.eclipse.persistence.exceptions.ConversionException
    Exception Description: The object [org.eclipse.persistence.platform.database.MySQL4Platform], of class [class java.lang.String], could not be converted to [class java.lang.Class]. Ensure that the class [org.eclipse.persistence.platform.database.MySQL4Platform] is on the CLASSPATH. You may need to use alternate API passing in the appropriate class loader as required, or setting it on the default ConversionManager
    Internal Exception: oracle.classloader.util.AnnotatedClassNotFoundException:
    Missing class: org.eclipse.persistence.platform.database.MySQL4Platform
    Dependent class: org.eclipse.persistence.internal.helper.ConversionManager
    Loader: sun.misc.Launcher$AppClassLoader@13288040
    Code-Source: /C:/Oracle/MiddlewarePS4/modules/org.eclipse.persistence_1.1.0.0_2-1.jar
    Configuration: /C:/Oracle/MiddlewarePS4/modules/org.eclipse.persistence_1.1.0.0_2-1.jar
    This load was initiated at default.composite.MySqlTest.soa_2c170363-5ad7-4578-8920-f30fb224a8d2:1.0 using the Class.forName() method.
    You may need to configure the connection settings in the deployment descriptor (i.e. DbAdapter.rar#META-INF/weblogic-ra.xml) and restart the server. This exception is considered not retriable, likely due to a modelling mistake.
    The invoked JCA adapter raised a resource exception.
    Please examine the above error message carefully to determine a resolution.

  • Creation of tables using JDBC or SQLJ in webdynpro application

    Hi,
    I am trying to create tables in javadictionary(MaxDB)using my WebDynpro application.I tried creating tables using SQLJ and JDBC.But I was not able to do it.I can select and insert data into already created tables.
    Whwn I tried creating a table using JDBC I encountered the following exception.
    com.sap.sql.log.OpenSQLException: The SQL statement "CREATE TABLE TMP_DEPID (DEPID varchar(10) NOT NULL,DEPNAME VARCHAR(25))" contains the syntax error[s]: Open SQL syntax error: CREATE ... TABLE is not supported
    SQL syntax error: "VARCHAR" is a reserved keyword and cannot be used as an unquoted identifier
    Does this mean that creating tables is not supported?
    Can anyone help me in this matter?
    Thanks in advance,
    regards
    ~Pradeep Shetty

    Hi Pradeep,
    Yes, OpenSQL does not support creation of tables. But why would you need to create tables at runtime?! The natural way is to create the model at design time of your application, i.e. with the Java DataDictionary.
    However, if for any reason you really need to create database tables at runtime, you can achieve this by using a non-OpenSQL datasource, e.g. you could create a VendorSQL one and use it to obtain JDBC connections in your app. See also http://help.sap.com/saphelp_nw04/helpdata/en/c0/3ad4d5cdc66447a188b582aad537d3/frameset.htm.
    Hope that helps!
    Vladimir

  • Problem with Progress DB while using to connect using JDBC Adapter

    Hi,
      I am facing Problem with Progress DB while using to connect using JDBC Adapter. I am getting the following error in auditlog file like,
    Error during database connection to the database URL  jdbc:JdbcProgress:T:156.5.31.65:2545:/mfgprodev/devbadb 
    /devsche/i_apoext.db using the  JDBC driver "com.progress.sql.jdbc.JdbcProgressDriver" : com.sap.aii.adapter.jdbc.sql.DriverManagerException: Unable to locate a suitable JDBC driver to establish a connection to URL " jdbc:JdbcProgress:T:156.5.31.65:2545:/mfgprodev/devbadb 
    /devsche/i_apoext.db "
    I tried using the following all URLs,
    1. jdbc:JdbcProgress:T:156.5.31.65:2545:i_apoext.       
    2. jdbc:JdbcProgress:T:156.5.31.65:2545:i_apoext.db     
    3.                                                      
    jdbc:JdbcProgress:T:156.5.31.65:2545:/mfgprodev/devbadb 
    /devsche/i_apoext.                                      
    4.                                                      
    jdbc:JdbcProgress:T:156.5.31.65:2545:/mfgprodev/devbadb 
    /devsche/i_apoext.db.                                  
    Can anyone please help me out in solving this issue.
    May be the cause for this is :
    1) The Wrong URL  format
    2) CLASSPATH is not setted properly..
    Can you look more into this stuff.
    Thanks,
    Soorya.

    Hi,
    To access any database fromm XI, using the JDBC adapter, the corresponding drivers have to be installed on the XI server.
    Just check this note 831162.
    Also, check this PDF to install Drivers in XI,
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/3867a582-0401-0010-6cbf-9644e49f1a10

  • 3rd party to sap using HTTP adapter

    Hi Folks,
        I'm sending some IDOC to sap from the 3rd party. I have to use HTTP adapter as sender and IDOC as receiver adapter.
    Can you please suggest me how to configure teh sender side. As I know there will be no such configuration for the sender adapter as it is HTTP then how the HTTP adapter will get the data sent by the 3rd party and how it will pass it on to the idoc adapter ?
    Regards....

    If you like to have more details about the http url
    then refer the below link
    http://help.sap.com/saphelp_nw70/helpdata/en/c9/775b3b82646c3ae10000000a114084/frameset.htm
    Rajesh

Maybe you are looking for

  • Why is Safari/Mac breaking this site?

    What can we do to make Safari/Mac view this site without errors? http://apcinternet.com/edenvale/ Site markup is 100% correct http://validator.w3.org/check?uri=http%3A%2F%2Fapcinternet.com%2Fedenvale%2F&cha rset=%28detect+automatically%29&doctype=Inl

  • Problems to see Flow Trace in production enviroment

    Hello, I have any problems to see the process flow trace from production Enterprise Manager but from development environment I can see it correctly Environment informations: · Development environment: Virtual machine in vmware ESXi 4.1 con S.O. Linux

  • Cant open Folder

    Today I was moving applications and other files from a portable hard drive onto my new mac. I was moving a large group of files (75 gigs) when finder suddenly quit half way through and went into a loop between a gray screen and my desktop. I tried to

  • TREX error code 6800 during preprocessing

    Can anyone tell me what error code 6800 during preprocessing stage means? Is there a list of error codes and what they mean? Any ideas on how I resolve this error? Im trying to index the contents of a web repository manager that contains a single (in

  • How to upgrade to the coming Lion OSX from 10.5.8

    I intend to upgrade to the coming Lion OSX version from 10.5.8. Reading the Apple home page I got the impression an upgrade is only possible from version 10.6.8. So is this true? greetings Angelo