Syntax errors in examples for UTL_LMS

The examples for UTL_LMS in
Oracle® Database PL/SQL Packages and Types Reference
10g Release 2 (10.2)
Part Number B14258-01
http://download-uk.oracle.com/docs/cd/B19306_01/appdev.102/b14258/u_lms.htm
contain syntax errors
Correct would be
DECLARE
   s varchar2(200);
   i  pls_integer;
BEGIN
   i:= utl_lms.get_message(26052, 'rdbms', 'ora', 'french', s);
   dbms_output.put_line('before format, message is: '||s);
   dbms_output.put_line('formatted message is: '||utl_lms.format_message(s, 9, 'my_column_name'));
END;
/and
DECLARE
  s varchar2(200);
  i pls_integer;
BEGIN
   i:=utl_lms.get_message(601, 'rdbms', 'oci', 'french', s);
   dbms_output.put_line('OCI--00601 is: '||s);
END;
/

Hello Martin,
This is a known problem with wlst-jython. One cannot catch syntax errors
programmatically. The only way is to avoid loading properties file
that may cause syntax errors.
I am curious though how can a user enter invalid properties via a script?
thanks,
-satya
Martin Gustavsson wrote:
Hi,
When there are syntax errors in WLST-script, the calling program will get no information about this.
In our case the calling program is ANT. If the user enters invalid properties it could cause syntax errors in the WLST script. But the ANT task always receive a successfull code back and doesn't know that it went wrong.
What is the workaround for this? How can I from WLST return a fail code so that ANT does not continue?
Regards,
Martin

Similar Messages

  • Declaration syntax error in 9iLite for Palm.

    Hi all..
    I have one problem with my application in C/C++ Codewarrior with odbc for Palm.
    When i compile the application any declaration of the type: class <any class> give me one declaration syntax error, this happen in odbc.h and aboutform.h of msql project.
    The problem is that when i compile msql_r8.mcp no error is generated, but when i treat compile my application with the same include files the error is generated.
    What is wrong?
    Thanks in advance.
    CCRD.

    Be sure to use double-quotes when doing an include statement. For example:
    #include "..\Languages\Borland C\Decl-32.h"
    It may help to start by compiling the examples in C:\program files\national instruments\ni-488.2\languages\borland c
    It may also help to do a search on the web about compiling and linking in Borland C.
    Randy Solomonson
    Applications Engineer
    National Instruments

  • Syntax error fix needed for "...getHelperForLanguage: function(language) null,..."

    Getting the syntax error, and having limited technical experience, I do not know how to fix the problem. This is in regard to a web site asset, an mp3 file. I am having problems getting such files to play within Chrome (though they play in Internet Explorer, for instance), so I am trying to troubleshoot from within Dreamweaver, as well as from the Chrome extensions side.
    Here is the line including the syntax error, with additional lines
        getInterfaces: function(countRef) {
            var interfaces = [Ci.nsIDOMGeoPositionCoords, Ci.nsIClassInfo, Ci.nsISupports];
            countRef.value = interfaces.length;
            return interfaces;
    getHelperForLanguage: function(language) null,
        contractID: "",
    Thanks for help.

    Use HTML5 <audio>. 
    <!doctype html>
    <html>
    <head>
    <meta charset="utf-8">
    <title>HTML5 Audio Demo</title>
    <!--[if lt IE 9]><script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
    </head>
    <body>
    <audio controls>
    <source src="path/yourSong.ogg" type="audio/ogg">
    <source src="path/yourSong.mp3" type="audio/mp3">
    <p>Ooooops.  Looks like your browser is out of date and doesn't support the audio tag.  Please upgrade to a modern browser.</p>
    </audio>
    </body>
    </html>
    Nancy O.

  • Syntax error on a for loop

    I am getting an error on the first line of the for statement. It says I need a semicolon but I can't seem to correct it and I know the error might not necessarily be on that line. I'm not sure how this even is going to print at the end of the switch statement but i can't compile it to find out. I can show you in another post what i am trying to achieve if it will help. Thanks.
    import javax.swing.*;
    import java.text.*;
    public class printNum
    public static void main (String [] args) {
    String startNumStr, endNumStr;
    int startNum, endNum;
    startNumStr= JOptionPane.showInputDialog(null, "Enter a starting number:");
    startNum = Integer.parseInt(startNumStr);
    endNumStr = JOptionPane.showInputDialog(null, "Enter an ending number:");
    endNum = Integer.parseInt(endNumStr);
    for(int startNum < endNum) {
    switch(startNum) {
    case startNum + 10:
    case startNum + 10:
    case startNum + 10: System.out.println(" " + startNum); break;
    default: System.out.println(" " + startNum);
    }

    I am getting an error on the first line of the for
    statement. It says I need a semicolon but I can't
    seem to correct it and I know the error might not
    necessarily be on that line. I'm not sure how this
    even is going to print at the end of the switch
    statement but i can't compile it to find out. I can
    show you in another post what i am trying to achieve
    if it will help. Thanks.
    import javax.swing.*;
    import java.text.*;
    public class printNum
    public static void main (String [] args) {
    String startNumStr, endNumStr;
    int startNum, endNum;
    startNumStr=
    tNumStr= JOptionPane.showInputDialog(null, "Enter a
    starting number:");
    startNum = Integer.parseInt(startNumStr);
    endNumStr = JOptionPane.showInputDialog(null,
    og(null, "Enter an ending number:");
    endNum = Integer.parseInt(endNumStr);
    for(int startNum < endNum) {
    switch(startNum) {
    case startNum + 10:
    case startNum + 10:
    case startNum + 10:
    e startNum + 10: System.out.println(" " + startNum);
    break;
    default: System.out.println(" " +
    ut.println(" " + startNum);
    }Why do you have the same case 3 times in the switch? Also, I don't think you can have variable expressions in the switch statement cases. I think these need to be constants.
    RD-R
    � {�                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • ECC syntax error for ADDFIELD.

    Dear Friends,
    I am getting a syntax error in ECC, for ADDFIELD.
    My original code is :
    data:   XI_SELTAB LIKE RSPARAMS OCCURS 0 WITH HEADER LINE.
          ADDFIELD XI_SELTAB 'ARBPL' V_GEWRK.
    Changed code is :
    *data:   XI_SELTAB LIKE RSPARAMS OCCURS 0 WITH HEADER LINE.
    TYPES: ty_XI_SELTAB TYPE RSPARAMS.
    Data:  XI_SELTAB TYPE  standard table of  ty_XI_SELTAB.
    Data:  wa_XI_SELTAB   type ty_XI_SELTAB.
    ADDFIELD WA_XI_SELTAB 'ARBPL' V_GEWRK.
    What is the exact syntax at here?? it not taking from work area.
    Thanks,
    Sridhar

    Sorry to all,
    Yes Its Micro and defined a like this :
    Macros
    DEFINE addfield.
      &1-sign = 'I'.
      &1-kind = 'S'.
    use operation cp if the value contains wildcards
      if &3 ca '*'.
        &1-option = 'CP'.
      else.
        &1-option = 'EQ'.
      endif.
    append the field name/value to the selection table
      if not &3 is initial.
        &1-selname = &2.
        &1-low     = &3.
        append &1.
      endif.
      clear &1.

  • Syntax error on INCLUDE STRUCTURE.

    Hi Experts,
    It is abit hard to explain what I need here.
    But I try to explain as much as I can.
    I am writing this code in order to update the customer material numbers into internal table tvbdpa. As you can see in my code, getting the customer material numbers require mapping the position number.
    I am stuck at the LOOP below with ***.
    Also getting the syntax error
    _The declaration for the key field "KDMAT" is imcomplete.
    However "KDMAT" is is contained in the key of table "TVBDPA" and must be filled._
    TABLES: vbco3.
    DATA: da_mess LIKE vbfs OCCURS 0 WITH HEADER LINE.
    DATA: BEGIN OF tvbdpa OCCURS 0,        "Internal table for items
            kdmat LIKE LIPS-KDMAT.
            INCLUDE STRUCTURE vbdpa.
    DATA: END OF tvbdpa.
    DATA: itab_vbak TYPE SORTED TABLE OF vbak
             WITH UNIQUE KEY vbeln,
          wa_vbak  LIKE LINE OF itab_vbak,
          itab_lips TYPE SORTED TABLE OF lips
             WITH UNIQUE KEY vbeln,
          wa_lips   LIKE LINE OF itab_lips,
          wa_tvbdpa LIKE LINE OF tvbdpa,
          lv_zuonr  TYPE vbak-zuonr.
      vbco3-mandt = sy-mandt.
      vbco3-spras = nast-spras.
      vbco3-vbeln = nast-objky.
      vbco3-kunde = nast-parnr.
      vbco3-parvw = nast-parvw.
    CALL FUNCTION 'RV_DOCUMENT_PRINT_VIEW'
      EXPORTING
        comwa                       = vbco3
      IMPORTING
        kopf                        = vbdka
      TABLES
        pos                         = tvbdpa
        mess                        = da_mess
      EXCEPTIONS
        fehler_bei_datenbeschaffung = 1.
    IF NOT tvbdpa[] IS INITIAL.
      SELECT SINGLE zuonr FROM vbak
        INTO lv_zuonr
        WHERE vbeln = vbdka-vbeln.
        IF sy-subrc = 0 AND lv_zuonr <> ''.
          SELECT vbeln posnr kdmat FROM lips
            INTO CORRESPONDING FIELDS OF TABLE itab_lips
            WHERE vbeln = lv_zuonr.
    ***I am stuck at here.
          LOOP AT itab_lips INTO wa_lips.
            READ TABLE tvbdpa INTO wa_tvbdpa
              WITH TABLE KEY posnr = wa_lips-posnr.
            wa_tvbdpa-kdmat = wa_lips-kdmat.
            MODIFY TABLE tvbdpa FROM wa_tvbdpa
                   TRANSPORTING kdmat.
          ENDLOOP.
    ***end I am stuck at here.
        ENDIF.
    ENDIF.
    All advise are welcome and greatly appreciated.
    Thanks in advance.

    Hi Subramanian,
    Does this more make sense for you?
    Can I read the table like :-
            READ TABLE itab_lips INTO wa_lips
              WITH TABLE KEY VBELN = wa_tvbdpa-matnr." AND POSNR = wa_tvbdpa-posnr.
    TABLES: vbco3.
    DATA: da_mess LIKE vbfs OCCURS 0 WITH HEADER LINE.
    DATA: BEGIN OF tvbdpa OCCURS 0,        "Internal table for items
            kdmat LIKE LIPS-KDMAT.
            INCLUDE STRUCTURE vbdpa.
    DATA: END OF tvbdpa.
    DATA: itab_vbak TYPE SORTED TABLE OF vbak
             WITH UNIQUE KEY vbeln,
          wa_vbak  LIKE LINE OF itab_vbak,
          itab_lips TYPE SORTED TABLE OF lips
             WITH UNIQUE KEY vbeln,
          wa_lips   LIKE LINE OF itab_lips,
          wa_tvbdpa LIKE LINE OF tvbdpa,
          lv_zuonr  TYPE vbak-zuonr.
      vbco3-mandt = sy-mandt.
      vbco3-spras = nast-spras.
      vbco3-vbeln = nast-objky.
      vbco3-kunde = nast-parnr.
      vbco3-parvw = nast-parvw.
    CALL FUNCTION 'RV_DOCUMENT_PRINT_VIEW'
      EXPORTING
        comwa                       = vbco3
      IMPORTING
        kopf                        = vbdka
      TABLES
        pos                         = tvbdpa
        mess                        = da_mess
      EXCEPTIONS
        fehler_bei_datenbeschaffung = 1.
    IF NOT tvbdpa[] IS INITIAL.
      SELECT SINGLE zuonr FROM vbak
        INTO lv_zuonr
        WHERE vbeln = vbdka-vbeln.
        IF sy-subrc = 0 AND lv_zuonr <> ''.
          SELECT vbeln posnr kdmat FROM lips
            INTO CORRESPONDING FIELDS OF TABLE itab_lips
            WHERE vbeln = lv_zuonr.
          LOOP AT tvbdpa INTO wa_tvbdpa.
            READ TABLE itab_lips INTO wa_lips
              WITH TABLE KEY VBELN = wa_tvbdpa-matnr." AND POSNR = wa_tvbdpa-posnr.
            wa_tvbdpa-kdmat = wa_lips-kdmat.
            MODIFY TABLE tvbdpa FROM wa_tvbdpa
                   TRANSPORTING kdmat.
          ENDLOOP.
        ENDIF.
    ENDIF.

  • Syntax error in For Loop statement

    Hello
    Normally my FOR staements have not been a problem as only access one table. I the example below I am accessing three table and therefore I get a Syntax error.
    I only wish to select the "Product" recored but need the other table to enable the select the right results.
    FOR product_rec IN (SELECT * from PRODUCT, PRODUCT_GROUP,PROD_PROD_GROUP
    where PRODUCT_GROUP.PRODUCT_GROUP_KEY = PROD_PROD_GROUP.PRODUCT_GROUP_KEY
    and PROD_PROD_GROUP.PRODUCT_KEY = PRODUCT.PRODUCT_KEY
    and product.supplier_key = company_no
    and PROD_PROD_GROUP.MULTI_WEB_DIS = 1
    order by PROD_PROD_GROUP.MULTI_WEB_SEQ)
    Can anyone let the correct syntx for this statement.
    Thanks
    Pete

    Like Dom said:
    FOR product_rec IN (SELECT PRODUCT.* from PRODUCT, PRODUCT_GROUP,PROD_PROD_GROUP
    where PRODUCT_GROUP.PRODUCT_GROUP_KEY = PROD_PROD_GROUP.PRODUCT_GROUP_KEY
    and PROD_PROD_GROUP.PRODUCT_KEY = PRODUCT.PRODUCT_KEY
    and product.supplier_key = company_no
    and PROD_PROD_GROUP.MULTI_WEB_DIS = 1
    order by PROD_PROD_GROUP.MULTI_WEB_SEQ) Or what he meant by "nice to have", use aliases:
    select p.*
    from
      product p,
      product_group pg,
      prod_prod_group ppg
    where
      pg.product_group_key = ppg.product_group_key
      and ppg.product_key = p.product_key
      and p.supplier_key = company_no
      and ppg.multi_web_dis = 1
    order by
      ppg.multi_web_seqAlso, note that company_no is not aliased in the above query. If this is a column, it should be aliased as well (either with the full table name or the alias if you switch to using them). If it is a PL/SQL variable, it is fine as is.
    Edited by: cmartin2 on Feb 2, 2011 1:56 PM

  • 11g gateway for ODBC returns SYNTAX ERROR on query

    Hi,
    I have made a database link to an odbc link on a 11g gateway. The odbc driver for the database in question is called connx, a third party driver to connect to RMS files on an old vax. The odbc driver works fine as I tested it independently of the gateway.
    The database link connection is fine. I do desc tablename and it returns the correct columns
    I do for example select * from SICF090MLT@melt and it returns :
    meltdb>select * from SICF090MLT@melt;
    select * from SICF090MLT@melt
    ERROR at line 1:
    ORA-28500: connection from ORACLE to a non-Oracle system returned this message:
    Illegal identifier
    A1."CHARGE_NO" , A1."MIX_ID" , A1."BUCKET_ID" , A1."AIM_ST" , A1."SCRAP_MIX_NAME" FROM << Syntax Error >> 'SICF090MLT' A1
    ORA-02063: preceding 3 lines from MELT
    As you can see all of the columns have been discovered by the query,
    I am not sure what can be the issue. Maybe a character translation issue? Some configuration settings for the gateway? Any ideas?
    On a side note: all other database links to other databases (sqlserver) work fine with this 11g gateway.
    The Best to all of you!

    Mireille,
    I am using a win32 driver.
    HS_FDS_SUPPORT_STATISTICS is false for all my database links. I have had issues with that in the past and have already learned my lesson :)
    I will check the quoted identifier setting for my odbc link and change it if I can.
    As a side note: for now I am using the DBMS_HS_PASSTHROUGH package to get around the problem, but it is better if I solve my original problem obviously. I will let you know.
    Merci et bonne journée.

  • SYntax error while creating a formula for %

    Hi All,
    I have to calculate Growth percentage and creating formula.  But its giving me a syntax error.
    I am writing like this:-
    (Month to Date Sales-MTD PRior Year Sales)/ MTD PRior Year Sales*100 %
    Can anyone please tell me where I am making a mistake.
    Regards

    Syntex for Percentage Deviation (%)
    Plan Sales % Actual Sales (this will give the percentage deviation between Planned Sales and Actual Sales)
    this is identical to formula
    100 * (Planned Sales - Actual Sales) / (Actual Sales)
    please check the space in your foumula
    Dev

  • Syntax error while creating tax codes for sales n purchases

    Hi all,
    While creating the tax codes for sales and purchases, i got the below error:
    Report RB13A003 has a syntax error.
    What should be done?
    Thank you

    Hi,
    I believe, it's RV13A003 report and not RB13A003... What is the exact error message (or is it a dump)?
    Regards,
    Eli

  • Why are my emails addressed to yahoo and mindspring clients being rejected for syntax errors?

    Here is the error message:
    Delivery to the following recipient failed permanently:
    Lisa@[email protected]
    Technical details of permanent failure:
    Google tried to deliver your message, but it was rejected by the server for the recipient domain yahoo.com by mta7.am0.yahoodns.net. [98.138.112.37].
    The error that the other server returned was:
    501 Syntax error in parameters or arguments

    Thanks, Zenos! My little test seemed to go through with no problems. One additional piece of information that puzzles me is that I used the address with the superfluous @ for two weeks before the failures - hmmmm.
    Having said that, I should not have used the @ in the address - period. It would be nice to have Thunderbird catch that when I entered the address initially. I am currently using Version 32.0, which I believe to be the latest version.
    Thanks for solving it so quickly!

  • MS SQL - Syntax error for valid query

    I have a problem with the second query in this code (gives me
    a syntax error in my HAVING line)
    <cfquery name="getDupes" datasource="#application.ODBC1#"
    dbtype="ODBC" username="#application.userNameODBC1#"
    password="#application.userPassODBC1#">
    SELECT *
    FROM view_FormCount
    WHERE formCount >= 2
    ORDER BY formNum
    </cfquery>
    <cfset variables.lstForms = "">
    <cfoutput query="getDupes">
    <cfset variables.lstForms=
    listAppend(variables.lstForms,"'#getDupes.formNum#'")>
    </cfoutput>
    <cfset variables.whereClause = "(formNum =
    #ReplaceNoCase(variables.lstForms,',',' OR formNum =
    ','ALL')#)">
    <cfquery name="getDetails"
    datasource="#application.ODBC1#" dbtype="ODBC"
    username="#application.userNameODBC1#"
    password="#application.userPassODBC1#">
    SELECT tblForms.formNum, tblForms.formName,
    tblForms.formCustNum, tblCompanies.companyAbbr
    FROM tblForms INNER JOIN tblCompanies ON tblForms.formCustNum
    = tblCompanies.companyNum
    GROUP BY tblForms.formNum, tblForms.formName,
    tblForms.formCustNum, tblCompanies.companyAbbr
    HAVING #variables.whereClause#
    ORDER BY tblForms.formNum, tblForms.formCustNum
    </cfquery>
    Now, the really odd thing is if I just take the query text
    out of the CFQUERY tags and use CFOUTPUT instead (to see in my
    browser what query is getting executed) I get a query that I can
    paste into Enterprise Mgr and runs fine.
    I can even paste the resulting text into my code in a CFQUERY
    and CF will run it fine.
    In other words, the dynamic version query gives me an error,
    but if I just output the SQL statement, copy-and-paste that into
    the CFQUERY that's erroring out (replacing what's there) to run as
    a static query, it works fine (sample of static query below).
    The error I get when I try to do it dynamically is "Error
    Executing Database Query. [Macromedia][SQLServer JDBC
    Driver][SQLServer]Line 4: Incorrect syntax near '10169318'. The
    error occurred on line 21." which is where the HAVING clause
    starts.
    SELECT tblForms.formNum, tblForms.formName,
    tblForms.formCustNum, tblCompanies.companyAbbr FROM tblForms INNER
    JOIN tblCompanies ON tblForms.formCustNum = tblCompanies.companyNum
    GROUP BY tblForms.formNum, tblForms.formName, tblForms.formCustNum,
    tblCompanies.companyAbbr HAVING (formNum = '10169318' OR formNum =
    '1016CONCERTA' OR formNum = '1016NSAIDS' OR formNum =
    '1016STRATTERA' OR formNum = '1016WELLBUTRIN' OR formNum =
    '18504211' OR formNum = '185093807' OR formNum = '73208565' OR
    formNum = '732120027' OR formNum = '7322154' OR formNum = '7323402'
    OR formNum = '7323522' OR formNum = '73238900' OR formNum =
    '7324211' OR formNum = '7324211S' OR formNum = '7324265' OR formNum
    = '73242891' OR formNum = '732434341' OR formNum = '732434342' OR
    formNum = '73243435' OR formNum = '73243436' OR formNum =
    '73243439' OR formNum = '73243440' OR formNum = '73243441' OR
    formNum = '73243442' OR formNum = '73243443' OR formNum = '7324359'
    OR formNum = '7324360' OR formNum = '7324370' OR formNum =
    '7324560' OR formNum = '7324959' OR formNum = '7326411ptreg' OR
    formNum = '7326599' OR formNum = '7326600' OR formNum = '7326620'
    OR formNum = '7326707' OR formNum = '7326931' OR formNum =
    '7328410' OR formNum = '732851031TOP' OR formNum = '7328512' OR
    formNum = '7328548' OR formNum = '7328548P2' OR formNum =
    '7328548P3' OR formNum = '7328548P4' OR formNum = '73289400' OR
    formNum = '73290D' OR formNum = '7329154' OR formNum =
    '73291544JHS' OR formNum = '73291545JHS' OR formNum =
    '73291546JHSMH' OR formNum = '73291547JHSMH' OR formNum = '7329174'
    OR formNum = '7329308' OR formNum = '7329402' OR formNum =
    '7329424' OR formNum = '7329455' OR formNum = '7329520' OR formNum
    = '7329539' OR formNum = '73297701JH' OR formNum = '73298273' OR
    formNum = '73298400' OR formNum = '73298403' OR formNum =
    '73298404' OR formNum = '7329883' OR formNum = '73298860' OR
    formNum = '7329887' OR formNum = '73298974' OR formNum = '7329899'
    OR formNum = '7329899S' OR formNum = '73299190' OR formNum =
    '7329987' OR formNum = '7329999PTO' OR formNum = '732AV5160' OR
    formNum = '732CMHFRAZ' OR formNum = '732HIPAA' OR formNum =
    '732HIPAAFLYERS' OR formNum = '734HEART' OR formNum = '7444711' OR
    formNum = '7449230' OR formNum = '744HR4991' OR formNum =
    '7538014MI' OR formNum = '77511044' OR formNum = '77511045' OR
    formNum = '775stampnochange' OR formNum = '80851001BLUE' OR formNum
    = '80MR4200' OR formNum = '80MR4273' OR formNum = '80MR4274' OR
    formNum = '80MR4300' OR formNum = '80MR9934' OR formNum =
    '80MR9935' OR formNum = '80SHC100' OR formNum = '80SHC4301' OR
    formNum = '80SHC9830' OR formNum = '80SHC9832') ORDER BY
    tblForms.formNum, tblForms.formCustNum

    AWFrueh1808 wrote:
    > OK, that's simple enough. But then I'm really confused
    as to why the query in
    > my original post/example didn't work.
    >
    > The only single quotes in my #whereClause# variable were
    wrapped around each
    > varchar value in the WHERE clause (well, HAVING) as in
    HAVING formNum = '12345'
    > OR formNum = '54321'
    >
    > I never used a single quote within the value itself. And
    yet
    > preservesinglequotes fixed it. So what was CF doing? Why
    did the single
    > quotes still show up in the error msg - and in the right
    place?
    >
    As I said the default behavior is to escape the quotes in
    your variables
    as data. So the default output of your SQL statement, before
    preserveSingleQuotes() would be like this.
    HAVING formNum = ''12345'' OR formNum = ''54321''
    As you can see that is not the desired results in your case.
    In your
    case you have the proper number of single quotes in your
    string and you
    do not want any added. You want to preserve them so to say.
    Thus
    adding preserveSingleQuotes() around your whereClase
    variable, i.e.
    preserveSingleQuotes(whereClause) says do not add any quotes,
    keep them
    all single.

  • XI Business content for MDM - Syntax error in IDOC adapter

    Hi mates,
    I'm trying out the Master Data Harmonization scenario for Vendor data with R/3 as the client system. I'm using SAP delivered XI Business content for MDM. The mapping program is generating ADRMAS and CREMAS IDocs but the IDOC adapter reports that there is a syntax error in ADRMAS IDOC. Find below the details.
    <i><SAP:Category>XIAdapter</SAP:Category>
      <SAP:Code area="IDOC_ADAPTER">ATTRIBUTE_IDOC_METADATA</SAP:Code>
      <SAP:P1>Segment 'E1BPAD1VL', segmentnumber '000001' not correct in structure ADRMAS02</SAP:P1>
      <SAP:P2 />
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText />
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack>Error: Segment 'E1BPAD1VL', segmentnumber '000001' not correct in structure ADRMAS02</SAP:Stack>
      <SAP:Retry>M</SAP:Retry></i>
    Generated ADRMAS IDOC is
    <i>  <?xml version="1.0" encoding="utf 8" ?>
      <ADRMAS02>
      <IDOC BEGIN="1">
      <EDI_DC40 SEGMENT="1" />
      <E1ADRMAS>
      <OBJ_TYPE>LFA1</OBJ_TYPE>
      <OBJ_ID>0000500140</OBJ_ID>
      <CONTEXT>0001</CONTEXT>
      <E1BPAD1VL SEGMENT="1">
      <FROM_DATE>00010101</FROM_DATE>
      <TO_DATE>99991231</TO_DATE>
      <NAME>Swift Transportation</NAME>
      <COUNTRY>US</COUNTRY>
      <COUNTRYISO>US</COUNTRYISO>
      <LANGU>E</LANGU>
      <LANGU_ISO>EN</LANGU_ISO>
      <SORT1>SWIFT TRANSPORTATION</SORT1>
      <TIME_ZONE>CST</TIME_ZONE>
      <E1BPAD1VL1 SEGMENT="1">
      <LANGU_CR>E</LANGU_CR>
      <LANGUCRISO>EN</LANGUCRISO>
      <ADDR_GROUP>BP</ADDR_GROUP>
      </E1BPAD1VL1>
      </E1BPAD1VL>
      </E1ADRMAS>
      </IDOC>
      </ADRMAS02></i>
    Strangely, the control record is blank. I looked at the XSLT program, it is coded that way. I do not understand the reason. Is the error pointing to the control record?
    Look at the code sample from XSLT mapping program
      <xsl:for-each select="IDOC/*/E1ADRMAS">
           <IDOC BEGIN="1">
           <!-- The header data of each single ADRMAS-IDoc needs to be there but does not require specific data -->
                <EDI_DC40 SEGMENT="1"/>
                <xsl:apply-templates select="."/>
           </IDOC> 
      </xsl:for-each>
    How can an IDOC w/o control record be posted?
    Did anyone come across this error? Whats wrong/missing?
    I appreciate ur inputs.
    thx in adv
    praveen

    Moorthy,
    I tried reloading the IDOC metadata from IDX2. Still I get the same error.
    Regd, IDOC w/o control record, can u elaborate on "dynamic value while posting IDOCs". From where, XI message SOAP header with Business System replaced by corresponding logical system names?
    Thanks
    Praveen

  • Syntax Error after creating enhancements for subroutine

    Problem:
    Creating enhancement sections gives a syntax error when creating enhancement options and implementations for a subroutine and then ceating enhancement options and implementations for the call to that same subroutine.
    <p>
    Syntax Error:
    "Different number of parameters in FORM and PERFORM (routine: SET_LAYOUT, number of formal parameters: 2, number of actual parameters: 1)
    </p>
    <p>
    Here's the following scenario:
    </p>
    <p>
    A subroutine is defined in a program.
    The subroutine is called within the same program.
    </p>
    <p>
    I then executed these steps:
    <br>     1. Defined an enhancement section around the subroutine definition
    <br>     2. Defined an enhancement section around the subroutine call.
    <br>     3. Implemented the enhancement section around the subroutine definition and add an additional parameter.
    </p>
    <p>
         Currently, this gives a syntax error as expected, since the call to the subroutine needs 1 more parameter.
    </p>
    <p>
         4. Implemented the enhancement section for the subroutine call.  I change the call in the implementation so it passes the new parameter.
    </p>
    <p>
    A syntax check to this gives an error.  The syntax checker is not only checking the new implementation, but also the original subroutine that should have been overwritten.
    </p>
    <p>
    The enhancement sections use the same enhancement spot, and the enhancement implementations use the same implementation.
    </p>
    <p>
    I tried various combinations of using different enhancement spots and/or implementations, but all give the same syntax error.  I tried separating the subroutine in a different include and  retried my testing, but it still gave the same syntax error.
    </p>
    <p>
    Here's the sample code I first created to try troubleshooting the problem:
    </p>
    <p>
    <pre>
    ENHANCEMENT-SECTION ZEP_Z_MICHAEL_02 SPOTS ZES_Z_MICHAEL .
         PERFORM set_layout
              CHANGING
              wa_layout.
    END-ENHANCEMENT-SECTION.
    $$-Start: ZEP_Z_MICHAEL_02----
    $$
    ENHANCEMENT 2  ZEI_TEST_SECTIONS.
         "inactive version
         PERFORM set_layout
         using 'X'
              CHANGING
              wa_layout.
    ENDENHANCEMENT.
    $$-End:   ZEP_Z_MICHAEL_02----
    $$
    ENHANCEMENT-SECTION ZEP_Z_MICHAEL_01 SPOTS ZES_Z_MICHAEL STATIC .
    FORM set_layout
    CHANGING p_wa_layout TYPE slis_layout_alv.
    p_wa_layout-zebra = 'X'.
    wa_layout-no_colhead = 'X'..
    p_wa_layout-colwidth_optimize ='X'.
    wa_layout-window_titlebar = 'Woot'.
    ENDFORM. "set_layout
    END-ENHANCEMENT-SECTION.
    $$-Start: ZEP_Z_MICHAEL_01----
    $$
    ENHANCEMENT 1  ZEI_TEST_SECTIONS.
         "inactive version
    FORM set_layout
    using p_test type boolean
    CHANGING p_wa_layout TYPE slis_layout_alv.
    p_wa_layout-zebra = 'X'.
    wa_layout-no_colhead = 'X'..
    p_wa_layout-colwidth_optimize ='X'.
    wa_layout-window_titlebar = 'Woot'.
    ENDFORM. "set_layout
    ENDENHANCEMENT.
    $$-End:   ZEP_Z_MICHAEL_01----
    $$
    </pre>
    </p>
    <p>
    Please let me know if you think I am doing something wrong. 
    </p>
    <p>
    Thanks, <br>
    Mike
    </p>
    Edited by: Michael Herman on Mar 8, 2010 8:11 PM

    Yes, Sandra.  That is what did and it worked with no syntax errors!
    I'm not sure if this is getting off topic or not, but the SAP documentation(taken from the SAP help after pressing F1 on the keyword static in ERP6) seems misleading:
    "The STATIC addition is intended for the enhancement of data declarations, while the statement ENHANCEMENT-POINT without the STATIC addition is designed for the enhancement of executable coding."
    I would think the enhancement section ZEP_Z_MICHAEL_02 would fall under the category of executable code, while the enhancement section ZEP_Z_MICHAEL_01 would fall under the category of declarative code.
    Unfortunately, all the SAP enhancement sections I come accross are dynamic.  The SAP help explains the reasoning for this:
    "In contrast to the statement ENHANCEMENT-POINT, the addition STATIC of the statement ENHANCEMENT-SECTION can only be used with maximum caution for changes of data declarations, because a replacement and no completion is carried out. Especially application development within SAP should not use the addition STATIC at all with ENHANCEMENT-SECTION as the change will be active in the entire customer system. "
    I do not know what the word "completion" means in the previous quote, so I can't determine why it would matter.  Regardless, if a developer wanted to change a standard subroutine declaration, they would also have to mod an enhancement section to change it to static.  This seems to defeat the purpose of using enhancements, but maybe this scenario is not what enhancements were intended for.

  • [Microsoft][ODBC driver for Oracle]Syntax error or access violation

    Hi,
    When I am trying to connect to Oracle 8.1.6 database using Microsoft ODBC driver for Oracle. The connection is established.
    But while creating CallableStatement, I am getting error "[Microsoft][ODBC driver for Oracle]Syntax error or access violation".
    What I need to do to resolve this problem.
    Raj

    Hi Satish
    It could be an issue with the driver.
    You can try with the OLEDB n Oracle native connection to test if the issue persists.
    Also you can refer to the [Troubleshooting Database Connectivity for Crystal Reports|http://www.sdn.sap.com/irj/boc/index?rid=/library/uuid/d05b3bb7-0f28-2c10-4ea3-84dbdc4e414e&overridelayout=true]
    Hope this helps!!
    Regards
    Sourashree

Maybe you are looking for