Goldengate:error in sqlexec clause

This is more than a table synchronization, using specific values instead of code
map cz.tbs_test1, target cz.tbs_test2,
sqlexec (id cs,
query “select a.ryxb,b.csdm,b.csmc xbmc,a.rymz,c.csdm,c.csmc mzmc
from cz.tbs_test2 a,
  (select csdm,csmc from cz.tbs_test3 where cslb=‘3’) b,
  (select csdm,csmc from cz.tbs_test3 where cslb=‘1’) c
where a.ryxb=:xb and a.rymz=:mz”,
params (xb=b.csdm, mz=c.csdm)),
colmap (usedefaults,
  csxbmc=@getval(cs.xbmc),
  csmzmc=@getval(cs.mzmc));
error in sqlexec clause, id cs:error in param clause for xb
a.ryxb=b.csdm and a.rymz=c.csdm
This is a.ryxb the code 1 and 2, according to my purpose is to transform into male and female to display.

Hey the escape character in java is \ you need to use that to escape the property of " for eg you will write like this ResultSet rs = stmt.executeQuery("SELECT OrderDate, ProdNumber, Quantity, Price, OrderNumber FROM Order WHERE EmailAddress= "\""+ email + "\"");
try this and let me know if it works

Similar Messages

  • Problem: Error in WHERE clause. Unrecognized clause or element.

    Hi All,
    i have a replicat and tried to filter some rows:
    This was my MAP-Statement in the param-file:
    MAP GOMS3KT, TARGET goldengate.txlog,
    COLMAP (
    tsid = #IDTIMESTAMP(),
    syskey = SYSKEY,
    type = "KT",
    trxtimestamp = #TRAILJULIANTS(),
    acquirer = #ACQFILTER(acq-id-schema_1,acquirer-id_1,log-item-length_2),
    origin = #ASSERTDEFAULT2(bezugssystem_1 ," " ,log-item-length_2),
    issuer = #MANIPULATEISSUER(bezugssystem_1, ISS-ID-SCHEMA_1, ISSUER-ID_1, -1, log-item-length_2)
    ) where (bezugssystem_1 = "PSVL");
    At runtime, i got this error:
    2013-02-25 09:09:42 WARNING OGG-00869 No unique key is defined for table 'TXLOG'. All viable columns will be used to represent the
    key, but may not guarantee uniqueness. KEYCOLS may be used to define the key.
    ...(bezugssystem_1 = "PSVL")...
    ^
    Error in WHERE clause. Unrecognized clause or element.
    The column 'bezugssystem_1' does exist, i mapped it before to a the oracle column 'origin'
    What is wrong here ??
    I i delete the where clause all works fine!
    Edited by: Felix_GG on 26.02.2013 15:44
    Edited by: Felix_GG on 26.02.2013 18:25

    Of course, in the where clause should stand a '=' or what i wrote (but is not able to show) the signs for NOT EQUAL, a 'less than' followed by a 'greater then'

  • Getting Error While Uploading Clause Document in SAP Sourcing 9.0

    Hi,
    --------------------system description--------------
    SAP Sourcing 9.0
    SAP NW7.31 AS JAVA
    IBM DB2 9.7
    I am getting error while executing clause document.
    ----------------------Error Description---------------
    Login with buyer link into the system-> it has all authorizations
    then Goto -> Contract Management -> Clause Library -> Clause list -> Click on New button -> Click on Add button -> Browse Document
    it is showing POPUP with Error that "There is a problem with the Contract Generation web service Contact your system administrator"
    Thanks and Regards,
    Murtaza Najmi

    Hi Gary,
    it is standalone system i have, everything i have installed on one server.
    i have already checked with restarting IIS server, and i can see word service while running url in contractgen.serviceurl, word service is running fine on browser but when i upload the document a popup window comes with error as i have shown above in my query
    Thanks once again Gary for replying
    Thanks and Regards,
    Murtaza Najmi

  • Exception: DBD, [Microsoft][ODBC Excel Driver] Syntax error in FROM clause.

    Dear experts,
    I'm trying to create an universe linked to an Excel File.
    I've created the ODBc connection and the DNS Data Source and inserted the table (table name RAC$) in the Universe. however, when I try to map each table field in the universe's Objects I'm getting this error message:
    "Exception: DBD, [ODBC Excel Driver] Syntax error in FROM clause.State:37000".
    I've tried to rename the table, inserting square brackects and also add new parameters to the universe («Transactional Available = "Yes"» and «Delimited Identifier = "Yes"») but still no solution to my problem.
    Any advice, tip or trick?
    Thank you. My best regards.
    Inês Santos

    Hi Ines,
    Thanks for sharing how you resolved this! I will bookmark this so that I can find it when I will likely need it!
    Bill
    Sorry I don't know how to make the accent circumflex! Or is that what you call it? On top of the e?
    Edited by: wavery on Jun 11, 2010 12:07 AM
    Edited by: wavery on Jun 11, 2010 12:09 AM

  • Error in FROM clause

    hi,
    ok i have a piece of code which looks like
    ResultSet rs = stmt.executeQuery("SELECT OrderDate, ProdNumber, Quantity, Price, OrderNumber FROM Order WHERE EmailAddress='" + email + "'");
    when i execute it... i get following error
    java.sql.SQLException: [Microsoft][ODBC Microsoft Access Driver] Syntax error in FROM clause.
    i don't think there is any problem with syntax...
    thanx in advance

    Hey the escape character in java is \ you need to use that to escape the property of " for eg you will write like this ResultSet rs = stmt.executeQuery("SELECT OrderDate, ProdNumber, Quantity, Price, OrderNumber FROM Order WHERE EmailAddress= "\""+ email + "\"");
    try this and let me know if it works

  • Stupid question: whats wrong here? -- Syntax Error in FROM clause

    i keep getting the error: Syntax Error in FROM clause.
    here is the code:
    <%@ page import="java.sql.*" %>
    <HTML>
    <HEAD>
         <TITLE>User Application Area</TITLE>
    </HEAD>
    <BODY BGCOLOR="#FFFFFF" TEXT="#000000">
    <%
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    Connection con = DriverManager.getConnection("jdbc:odbc:fypproject","","");
    Statement st = con.createStatement();
    String email = (String)session.getAttribute("email");
    String levelStatus = (String)session.getAttribute("levelStatus");
    String details = "SELECT PD.Forename, PD.Surname, L.Level_Name FROM PD Personal_Details AND LD Login_Details AND L Level WHERE PD.Email_Address = LD.Email_Address AND LD.Level_ID = L.Level_ID AND Level_ID = '" + levelStatus + "'";
    ResultSet rsDet = st.executeQuery(details);
    if(rsDet.next()) {
    String forename = rsDet.getString("Forename");
    String surname = rsDet.getString("Surname");
    String level_name = rsDet.getString("Level_Name");
    %>
    <DIV ALIGN="center"><H1>User Application Arena</H1></DIV>
    <BR>
    <H4>Welcome back <% out.println(forename + " " + surname); %> </H4>
    <BR>
    <%
    out.println(level_name);
    else {
    out.println("NOT FOUND ANYTHING");
    st.close();
    con.close();
    %>
    </BODY>
    </HTML>
    the strange thing is when i write a query that doesn't involve the 'Level' table it works fine.
    for example if i just want to display the forename and surname from 'Personal_Details' where the Email_Address = email it works fine...as soon as i involve the 'Level' table i get this error.
    i basically have 'Level_ID' in the 'Login_Details' table which is found out in the preceding jsp and passed through to this page and i can print out the Level_ID
    but....what i want to do is use this Level_ID and find the respective Level_Name in the Level table.
    my Level table looks like this:
    Level_ID Level_Name
    0 Pending
    1 Interview
    2 Rejection
    Thanks :o)

    Perhaps this is your issue ...
    The column Level_ID is in both the Login_Details and Level tables. Therefore, in your WHERE clause, you must specify a table alias for each reference to Level_ID
    WHERE PD.Email_Address = LD.Email_Address AND LD.Level_ID = L.Level_ID AND Level_ID = '" + levelStatus + "'";
    should be
    WHERE PD.Email_Address = LD.Email_Address AND LD.Level_ID = L.Level_ID AND L.Level_ID = '" + levelStatus + "'"; //ADDED "L." before Level_ID
    Level_ID would have been unique until you added the Level table.
    Good luck.
    -Mark

  • Syntax error in From clause from Access

    I am trying to migrate a database from Access 2000, and all of the tables except one migrate correctly. The one problem table gives me the following error message:
    Unable to migrate table data: NWQ_TANC.PARAMETERS; [Microsoft][ODBC Microsoft Access Driver] Syntax error in FROM clause.
    Does anyone know how to fix this? I have found the error in the help Appendix, but it just lists it as a QUERY type error, #3131, and gives no explanation or clues on how to fix it.
    Thanks, Jessica

    Hi Jessica
    Just wondering if you ever managed to find a solution to this problem, as I am getting a very similar error - only I don't just get it for one table, I get it for every single table in the database!
    Would be very interested to hear if you managed to sort it or not
    Cheers
    Ed

  • DATAMOVER: Error: Syntax error in where clause for PSOPRDEFN

    SET LOG C:\PSUSER_HRM.log;
    SET input F:\psoprdefn.dat;
    IMPORT psoprdefn where OPRId = 'PS';
    when i execute this command after importing .dat file from my database i get error:
    Error: Syntax error in where clause for PSOPRDEFN
    any suggestions pls help....
    Thanks
    aravind
    Edited by: 967641 on Nov 20, 2012 11:39 AM
    Edited by: 967641 on Nov 20, 2012 11:40 AM

    That is correct.
    Datamover tries to insert data in PSOPRDEFN and rows exist with these keys.
    To avoid this you can add the following statement in your script:
    SET UPDATE_DUPS;
    This will update the values other than the keys if a row already exists in the database with the keys in the dat file.
    I can advice you to buy the new book of Jim Marion, PeopleSoft PeopleTools Data Management and Upgrade Handbook
    http://www.amazon.com/PeopleSoft-PeopleTools-Management-Upgrade-Handbook/dp/0071787925/ref=sr_1_1?ie=UTF8&qid=1353575734&sr=8-1&keywords=jim+j+marion
    It has an entire chapter on how to use datamover.
    Hakan

  • How to convert string to date and check date difference in filter clause | error in filter clause

    Hi All,
    I have a requirement where i want to stop replicat if particular record is encountered on target.
    if PARAMETER_CODE="APPLDATE" and difference between parameter_value is 1 then replicat should stop.
    the code i am using is,
    map schema.src_tablename , target schema.trg_tablename, &
    WHERE(PARAMETER_CODE="APPLDATE"), &
    filter (on updates, (@to_date(before.PARAMETER_VALUE,'dd/mm/yyyy hh24:mi:ss')) - (@to_date(PARAMETER_VALUE,'dd/mm/yyyy hh24:mi:ss')) =1), &
    EVENTACTIONS(STOP);
    Replicat process abends with error in filter clause.
    Concern here is the parameter_value column is in varchar2 and not in date. (if its date than filter (on updates, @datediff ("DD",before.PARAMETER_VALUE, PARAMETER_VALUE) =1)  is working correctly). I need to stop replicat when date(in varchar2 format) gets incremented by 1.
    Please do help in solving the issue.
    Thanks,
    TrushB.

    Dear all,
    Please do update... how to covert a varchar2 to date in GG.

  • Error in COLMAP clause. Column name not found

    Hi guys,
    I must be missing something extremely simple here but I can't figure it out. I have a very simple test I am trying to perform. Remap a column from 1 table into another on replicat.
    I have created the defgens file.
    * Definitions created/modified 2013-02-12 13:08
    * Field descriptions for each column entry:
    * 1 Name
    * 2 Data Type
    * 3 External Length
    * 4 Fetch Offset
    * 5 Scale
    * 6 Level
    * 7 Null
    * 8 Bump if Odd
    * 9 Internal Length
    * 10 Binary Length
    * 11 Table Length
    * 12 Most Significant DT
    * 13 Least Significant DT
    * 14 High Precision
    * 15 Low Precision
    * 16 Elementary Item
    * 17 Occurs
    * 18 Key Column
    * 19 Sub Data Type
    Definition for table BILLING.B1
    Record length: 92
    Syskey: 0
    Columns: 2
    B_ID 64 50 0 0 0 1 0 50 50 50 0 0 0 0 1 0 1 2
    B_F_NAME 64 30 56 0 0 1 0 30 30 0 0 0 0 0 1 0 0 0
    End of definition
    Definition for table BILLING.B2
    Record length: 92
    Syskey: 0
    Columns: 2
    B_ID 64 50 0 0 0 1 0 50 50 50 0 0 0 0 1 0 1 2
    B_L_NAME 64 30 56 0 0 1 0 30 30 0 0 0 0 0 1 0 1 0
    End of definition
    I have setup the replicat to read the sourcedefs and remap the column
    -- Identify the Replicat group:
    REPLICAT rxtest
    -- State that source and target definitions are identical:
    --ASSUMETARGETDEFS
    SOURCEDEFS /u12/oracle/golden_gate_11_rep/dirsql/defgen_billing.sql
    --Discard Setup
    DISCARDFILE /u12/oracle/golden_gate_11_rep/dirout/rxtest.txt , PURGE
    SETENV (NLS_LANG="AMERICAN_AMERICA.WE8MSWIN1252")
    -- Specify database login information as needed for the database:
    USERID gg, PASSWORD
    -- Specify error handling rules:
    REPERROR (DEFAULT, ABEND)
    DDL EXCLUDE ALL
    MAP billing.b1, TARGET billing.r1,
    COLMAP (
    B_ID = id,
    b_f_name = f_name);
    Now when I try and start the rxtest replicat I get this error in the report.
    MAP resolved (entry BILLING.B1):
    MAP BILLING.B1, TARGET billing.r1, COLMAP ( B_ID = id, b_f_name = f_name);
    ...( B_ID = id, b_f_name = f_name...
    ^
    Error in COLMAP clause. Column name not found.
    Any ideas? Thanks

    desc billing.r1 - does that table have columns that you've included in the map clause?
    But, check the ordering of the columns in colmap - it goes target_column_name = source_column_name, looks like you have that reversed.
    I don't know why people insist on using SQL file extensions on def files, and placing them in the dirsql directory. What was wrong with using the (already created for you) dirdef directory? And naming the file with an extension like def or defs? It is not a SQL file.

  • Error adding defaultPackage clause in XML Publisher

    Hi XML Gurus
    I'm trying to output data using data templates in XML Publisher.
    My data template dumps XML data ok, but if I add defaultPackage clause , then I get this messagge executing concurrent:
    XDO Data Engine Version No: 5.6.3
    Calling XDO Data Engine...
    [072612_054320130][][EXCEPTION] SQLException encounter while executing data trigger....
    java.sql.SQLException: ORA-06550: line 2, column 11:
    PL/SQL: Statement ignored
         at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:112)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:331)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:288)
    No dataTrigger elements exist.
    Offending clause seems to be: defaultPackage="MY_PKG"
    MY_PKG is an existing package in apps schema.
    Of course, I can delete defaultPackage attribute, but my next step is to use dataTrigger(s)
    Any guidance please
    Oscar

    I found the answer by myself.....
    This error ocurrs because I need to declare any parameter as variable in package specification.
    Thanks anyway
    Oscar

  • Error while Generating Clause/section/contract template

    Hi,
    When I try to generate clauses, sections or contract document template, at the time of uploading the .doc file, the system is throwing an error like, "There is a problem with contract generation web service. Please contact your system administrator." How do I solve this error? I am using SAP Sourcing 7.0
    Thanks and Regards,
    Manan Nagori

    Hi
    This is a common error that mainly happen when the call to contract gen service is not resolved. Plz check whether your contract gen web service link http://<hostname>:<port>/WordService/wordservice.asmx is up or not.
    Also restart the contract gen server  and check once
    Regards
    Mudit Saini

  • Error in RETURNING clause in INSERT.....SELECT query

    Hi Friends
    I am having an error: "SQL stmt not properly ended" when i run the below code.
    Cant i fetch multiple values from the returning clause into a collection variable??
    insert into consumption__C
         (SITECODE, SALESORG, PRODFAM,CAMPCODE, CYEAR, MDATE, SYSENV, MTYPE, ACCOUNT__C, SUPPLIER__C,
    PRODUCT_PER_UNIT__C, PRODUCT__C, UNIT__C, AMOUNT_Y__C, VOLUME_Y__C, CURRENCY__C,SUPPLYMODE__C)
         select      ' '                    Sitecode,
                        ' '          Salesorg,
    ' '                    Prodfam,
                        ' '                    campcode,
                        ' '                    cyear,
                        pcurr_mig               MDATE,
                        psysenv                    SYSENV,
                        'NSet'                    MTYPE,                          
                        c.sitecode               Account__c,
                        ' '                    supplier__c,
                        ' '                    Product_per_unit__c,
                        c.material               Product__c,
                        ' '                    unit__c,
                        c.Amount           Amount_y__c,
                        ' '                    Volume__c,
                        'Euro'                    Currency__c,
                        ' '                    Supply_Mode__c
    from load_sales_customer_site c     returning c.customer_code bulk collect INTO temp;
    Kindly guide...... what is the problem!!
    Thanks in advance

    nice idea, but you can't use returning into with
    insert as select:
    SQL> select * from v$version;
    BANNER
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bi
    PL/SQL Release 10.2.0.1.0 - Production
    CORE    10.2.0.1.0      Production
    TNS for Linux: Version 10.2.0.1.0 - Production
    NLSRTL Version 10.2.0.1.0 - Production
    SQL> create table exm(id primary key) as select object_id from all_objects
      2  where rownum <=100;
    Table created.
    SQL> declare
      2  type num_tbl is table of number;
      3   ll_num_tbl num_tbl;
      4   begin
      5   insert into exm(id)
      6  (select object_id * 100 from all_objects where rownum
      7   <=100) returning id into ll_num_tbl;
      8  end;
      9  /
    <=100) returning id into ll_num_tbl;
    ERROR at line 7:
    ORA-06550: line 7, column 9:
    PL/SQL: ORA-00933: SQL command not properly ended
    ORA-06550: line 5, column 2:
    PL/SQL: SQL Statement ignoredAmiel

  • SQL error with LIKE clause in statement

    Can anyone explain how an SQL statement with a LIKE clause is executed properly?
    Seems like it ought to be cut and dried, no pun intended!
    When I run the following and set the requestor name = ?, and correctly type in the entire name, a result set (albeit abbreviated) will return.
    But if I try to set the request param to LIKE I get an error of some kind, either invalid cursor state or NullPointer exception.
    Here's my code.
    Statement selstmt = connection.createStatement();          
    String preparedQuery = "SELECT DISTINCT AID, ACTIVE, REQUESTOR_NAME,REQUESTOR_EMAIL" +
    " FROM CHANGE_CONTROL_USER, CHANGE_CONTROL_ADMIN " +
    " WHERE REQUESTOR_NAME LIKE '%?%';";
      String reqName = request.getParameter("requestor_name");
    PreparedStatement prepstmt = connection.prepareStatement(preparedQuery);
    prepstmt.setString(1, reqName);
    ResultSet rslts = prepstmt.executeQuery();
    rslts.next();
    int aidn = rslts.getInt(1);          
    int actbox = rslts.getInt(2);      
    String reqname = rslts.getString(3);
    String reqemails = rslts.getString(4);It's also returning only 1 record for some reason, as I have the following:
    <% while (rslts.next()) { %>
      <tr class="style17">
        <td><%=reqname%></td>
    <td><%=reqemails%></td>
       <td><%=actbox %></td>
        <td><%=aidn %></td>
      </tr>
      <%
    rslts.close();
    selstmt.close();
    %>If I use
    " FROM CHANGE_CONTROL_USER, CHANGE_CONTROL_ADMIN " +
    " WHERE REQUESTOR_NAME = ?;";it will actually spit out the name and corresponding email properly, albeit just one record like I said.
    Is there some kind of escape sequence I should be using that I'm not?
    And why just the one record?
    Any help or direction is appreciated!
    Thanks.

    I have working code for LIKE in PreparedStatement, and its equivalent in your case is something like this:Statement selstmt = connection.createStatement();          
    String preparedQuery = "SELECT DISTINCT AID, ACTIVE, REQUESTOR_NAME,REQUESTOR_EMAIL" +
    " FROM CHANGE_CONTROL_USER, CHANGE_CONTROL_ADMIN " +
    " WHERE REQUESTOR_NAME LIKE ?";
      String reqName = request.getParameter("requestor_name");
    PreparedStatement prepstmt = connection.prepareStatement(preparedQuery);
    prepstmt.setString(1, "%" + reqName.trim() + "%");
    ResultSet rslts = prepstmt.executeQuery();
    rslts.next();
    int aidn = rslts.getInt(1);          
    int actbox = rslts.getInt(2);      
    String reqname = rslts.getString(3);
    String reqemails = rslts.getString(4);

  • Errors in finally clause ?

    It appears that errors in a "finally" clause go completely undetected and unremarked, except that
    they change the return value to undefined
    function foo1(a) { return(a); }
    function foo2(a) { try { return(a); } finally { "no effect" ; }}
    function foo3(a) { try { return(a); } finally { b; "no effect"; }}     // "b" is a simulated typo
    function foo4(a) { try { b; return(a); } finally { "no effect"; }}     // "b" is a simulated typo
    It seems to me that foo3 ought to throw an error, or lacking that, return a.
    It does neither. It returns undefined.
    foo4 throws an error as I would expect.

    Wouldn't return force the function to exit immediately and ignore any code after it? I would suggest $.write() for the debugging and I would expect foo3 to return a as well. I will try it tomorrow, unless someone gives an explanation before.

Maybe you are looking for

  • My MacBook Pro is running really slow.

    Hey. My MBP has been running very slow for some time, and its becoming very frustrating. Straight after I start it up it starts running slow...I have 'Memory Clean' (not sure whether this is helpful or not) and as soon as i my Macbook loads it tells

  • Broadcast monitor vs XRite i1?

    After NAB I had finally settled on getting a "budget minded" Flanders Scientific monitor for our basic workflow of color correction and grading, etc. Then today I saw a webinar on the XRite i1 Display Pro. Apparently it can now calibrate to Rec 709.

  • The On My Mac mailboxes greyed out

    Recently I was having trouble with sending out emails from a couple of my accounts which use the same server, so I did all the usual stuff: repaired permissions, did a PRAM, deleted and re-created accounts, etc. Finally I trashed the old .plist and s

  • Change any paragraph style by script

    Hi !!! Is it possible change a selected paragraph with any paragraph style by script? Example: My paragraph style is: Font: Garamond, size 7pt, color: black, align justfy (or any selected paragraph style) Script to set the selected paragraph with par

  • Continuous data send and receive with unknown source

    When I connect my ipad to the lightning cable, no matter if it is connected to PC or it is going to be charged, if the wifi is on, it will start sending and receiving data continuously and with a high speed. I want to stop this thing from happening b