Error in DBMS_SQL Package (Very Urgent)

Hi Fellows,
I have created a procedure with two parameters (eg. disabletrigger(owner, tablename). I have used DBMS_SQL Package. The procedure has compiled successfully but when I run this procedure it returns this message.
ERROR at line 1:
ORA-00911: invalid character
ORA-06512: at "SYS.DBMS_SYS_SQL", line 782
ORA-06512: at "SYS.DBMS_SQL", line 32
ORA-06512: at "HABEEB.DIS", line 32
ORA-06512: at line 1
can any body help me in this ...
Thanks in advance
Mustafa

Hi Mustafa
Since DBMS_SQL package parses the DML or DDL statement that you issue at runtime, your code may have compiled successfully, but at runtime when your SQL/DML statement that you had embedded as a string in DBMS_SQL may be wrong or has syntax problems which gets resoved at runtime.
So check your SQL statement in DBMS_SQL package again.
NOTE: DO NOT GIVE A ";" AT THE END OF YOUR DML/DDL statement in DBMS_SQL package.
THANKS
MOHAMMED R.QURASHI
<BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Mustafa Butt ([email protected]):
Hi Fellows,
I have created a procedure with two parameters (eg. disabletrigger(owner, tablename). I have used DBMS_SQL Package. The procedure has compiled successfully but when I run this procedure it returns this message.
ERROR at line 1:
ORA-00911: invalid character
ORA-06512: at "SYS.DBMS_SYS_SQL", line 782
ORA-06512: at "SYS.DBMS_SQL", line 32
ORA-06512: at "HABEEB.DIS", line 32
ORA-06512: at line 1
can any body help me in this ...
Thanks in advance
Mustafa<HR></BLOCKQUOTE>
null

Similar Messages

  • Error 12  While Transporting - Very Urgent

    Hi all,
    we are transporting objects from Development to Production and we are facing with an error,
    Transfer structure 0UC_AKLASSE_TEXT_BB does not exist                       
    Error RSAR 440 when handling objects with type R3TR ISTS                                                                               
    Start of the after-import method for object type R3TR ISIP (Activation Mode)
    Start of the after-import method for object type R3TR ISIP (Delete Mode)                                                                               
    tried solving this problem by retransporting and by activating the structure in RS_TRANSTRU_ACTIVATE_ALL as mentioned in few posts,  still we are getting the same error, unable to find out the root cause, please help me in solving this is very urgent.
    Thanks in Advance,
    Sai..,

    Hi Edwin,
    I have gone through that note already no much information available there its mentioned about service package 04 with is already available in our system, as per your second check point source system is mapped fine as we are able to transport remaining objects, actually now we started transporting objects in batch wise selecting few at a time and as its working fine with few, I dont think there is a problem with mapping. and one more error we are getting is
    After transporting the objects in Production if we click infopackage,
    Caution ! - The transfer method has changed
    and in InfoPackage Processing level its showing
    Update Data
    ALE Inbox and InfoObject
    ALE Inbox only
    This is happening for few randomly and for others its fine with regualar processing PSA and then in InfoObject....,
    Please look into this as well.
    Thanks,
    Sai.

  • Time out error in oracle reports--very urgent

    Hi
    I have this oracle report on 9i which calls 14 other reports and runs them
    via a wrapper report which I run from a URL
    However I get this engine null crashed error or else Engine rwEng-0 is destroyed due to timeout error.
    From what I understand there is a timeout issue happening bcoz reports is taking a long time to run.Hence I increased the value of engineResponseTimeOut but it does not help either.Would you have any other idea to resolve this issue?
    Could someone plz tell me urgently how can this be resolved.This is on Oracle 9i.
    Thanks

    Hi Ravi kanth,
    You are using select * statement which is very time consuming and low performance. Dont use select * instead use select field1 field2.... into table itab  where field1 = s_field.  Use corresponding field names in the select statement.
    Follow the below rules.
    1) Dont use nested select statements
    2) If possible use for all entries in addition
    3) In the where addition make sure you give all the primary key
    4) Use Index for the selection criteria.
    5) You can also use inner joins
    6) You can try to put the data from the first select statement into an Itab and then in order to select the data from the second table use for all entries in.
    7) Use the runtime analysis SE30 and SQL Trace (ST05) to identify the performance and also to identify where the load is heavy, so that you can change the code accordingly
    <b>reward if useful</b>.
    Regards,
    sunil kairam.

  • Error in posting key-very urgent

    Dear expert,
    Please advice. My client do mistake when running manual posting (program for replacing EXITSAPLIEO1_007_in Good Receipt). This program is manual posting after GR created and will made posting key for credit entry (posting key 50, display in FBL3N. In program, we input material and comnos. The problem is, the PO is already GR in year 2004.
    What should I do to cancell this error (we would like the PK/this PO not appear in report this year-FBL3N).I have tried to do reversal doc for material and comnos contain error in the program, but still facing error in FBL3N.
    Please your advice very soon.
    Thank you in advance.

    In FBL3N we can see PO doc with posting key 40 & 50. (G/L account xxx-Stock in entreport).This is AP transaction-integration with MM module.The posting key 50, will be created after GR posting using manual posting program (called : ZGR=program for replacing EXIT_SAPLIE01in Good Receipt).
    There was mistake that my client re-run for GR which already posting before (in year 2004). It makes error in report (FBL3N) that the PO (GR in year 2004) appeared with only PK 50.This is would make total amount report for this month/year 2007 error).
    How could I cancelled the posting that my client have made? We would like no amount for the PO which reposting by my client not appeared in the report.FBL3N(delete / cancell)
    Please advice. Thank you.

  • Error :File not found -- Very Urgent

    Hi DBA's
    Instance --R12,
    OS -- Tru Unix64
    Problem--
    I am not able to load the page.
    i bounce the Apache and Clear the Catche still i am getting the same error.
    I have checked in the errorlog file it has given the bellow error..
    [Fri Aug 29 00:21:17 2008] [notice] Oracle-Application-Server-10g/10.1.3.1.0 Oracle-HTTP-Server configured -- resuming normal operations
    [Fri Aug 29 00:21:17 2008] [notice] Accept mutex: fcntl (Default: fcntl)
    [Fri Aug 29 00:36:47 2008] [notice] Oracle-Application-Server-10g/10.1.3.1.0 Oracle-HTTP-Server configured -- resuming normal operations
    [Fri Aug 29 00:36:47 2008] [notice] Accept mutex: fcntl (Default: fcntl)
    [Fri Aug 29 01:51:20 2008] [error] [client 130.29.133.55] [ecid: 1219999880:130.29.135.219:15002:0:14,0] File does not exist: /opt/oracle/admin/OICD/inst/app
    s/OICD_edevdb9/portal/favicon.ico
    [Fri Aug 29 03:40:37 2008] [error] [client 130.29.133.55] [ecid: 1220006437:130.29.135.219:16160:0:42,0] File does not exist: /opt/oracle/admin/OICD/inst/app
    s/OICD_edevdb9/portal/favicon.ico
    [Fri Aug 29 03:55:07 2008] [notice] Oracle-Application-Server-10g/10.1.3.1.0 Oracle-HTTP-Server configured -- resuming normal operations
    [Fri Aug 29 03:55:07 2008] [notice] Accept mutex: fcntl (Default: fcntl)
    Pls team help me to sort this problem.
    Regards.
    SG

    Hi DBA's
    I did the same thing now also, this is the error log..
    [Fri Aug 29 00:21:17 2008] [notice] Oracle-Application-Server-10g/10.1.3.1.0 Oracle-HTTP-Server configured -- resuming normal operations
    [Fri Aug 29 00:21:17 2008] [notice] Accept mutex: fcntl (Default: fcntl)
    [Fri Aug 29 00:36:47 2008] [notice] Oracle-Application-Server-10g/10.1.3.1.0 Oracle-HTTP-Server configured -- resuming normal operations
    [Fri Aug 29 00:36:47 2008] [notice] Accept mutex: fcntl (Default: fcntl)
    [Fri Aug 29 01:51:20 2008] [error] [client 130.29.133.55] [ecid: 1219999880:130.29.135.219:15002:0:14,0] File does not exist: /opt/oracle/admin/OICD/inst/apps/OICD_edevdb9/portal/favicon.ico
    [Fri Aug 29 03:40:37 2008] [error] [client 130.29.133.55] [ecid: 1220006437:130.29.135.219:16160:0:42,0] File does not exist: /opt/oracle/admin/OICD/inst/apps/OICD_edevdb9/portal/favicon.ico
    [Fri Aug 29 03:55:07 2008] [notice] Oracle-Application-Server-10g/10.1.3.1.0 Oracle-HTTP-Server configured -- resuming normal operations
    [Fri Aug 29 03:55:07 2008] [notice] Accept mutex: fcntl (Default: fcntl)
    [Fri Aug 29 05:54:04 2008] [notice] Oracle-Application-Server-10g/10.1.3.1.0 Oracle-HTTP-Server configured -- resuming normal operations
    [Fri Aug 29 05:54:04 2008] [notice] Accept mutex: fcntl (Default: fcntl)
    [applmgr@edevdb9:OICD]:/opt/oracle/admin/OICD/inst/apps/OICD_edevdb9/logs/ora/10.1.3/Apache > date
    Fri Aug 29 05:56:51 PDT 2008
    [applmgr@edevdb9:OICD]:/opt/oracle/admin/OICD/inst/apps/OICD_edevdb9/logs/ora/10.1.3/Apache >
    Regards,
    SG

  • Javax Activation error, pls help me very urgent

    Hello,
    I am calling a java stored procedure, but I am getting the following error:
    javax.activation.UnsupportedDataTypeException: no object DCH for MIME type multipart/mixed;
    boundary="----=_Part_0_-1403249095.1105388630390"
    I dropped the jar files from the database and re-deployed the the latest jar files downloaded from Sun site, still I am getting the the same error.
    could someone please help me with this, I am desperately trying to solve this problem and get the work done. I am using java stored procedure to send emails.
    Any help is highly appreciated.
    Thanks
    Cosmos

    This is a Javamail problem.
    with a quick search of the javamail forum i found the same problem: http://forum.java.sun.com/thread.jspa?threadID=74127&start=0&tstart=0

  • Sync Message Error. Pls help very urgent.

    Hi,
    When I ma sending sync messages in XI I am getting error
    <SAP:Code area="PERSIST">MSG_NOT_FOUND</SAP:Code>
    <SAP:P1>4871E583B6C24C3CE1000000AC140A3B</SAP:P1>
      <SAP:P2>PE_ADAPTER</SAP:P2>
    Pls help.

    Http sender  and Http Receiver so no adapter is used..

  • Response already commited error. Please help very urgent

    Hello,
    I am getting "RESPONSE HAS ALREADY BEEN COMMITED" error, when I open a report.
    Please explain why do the get this error and how can I prevent it from coming.
    Thanks in advance.
    Raghu

    Can't really give much more than general guidelines as you haven't provided that much information.
    A stack trace indicating what caused the "response already commited" error would be useful in diagnosis...
    HTTP is one request, one response.
    You get a request, you can only send one response to it.
    When dealing with a JSP your response html text gets written to a buffer, and then to the output stream.
    You can change your response output any time until the output is committed.
    The response gets committed if
    - the buffer fills up with data. The default size of the buffer on a JSP page is 8kb If more than 8kb of data is written, then it will commit the response. You can change the size of the buffer with the [<%@ page %> directive|http://java.sun.com/products/jsp/syntax/2.0/syntaxref2010.html#15653]
    - you flush the output buffer manually
    What sort of things cause the buffer to be cleared and reset? Anything that changes your response completely.
    The obvious causes:
    - a jsp:forward
    - a response.sendRedirect
    - an exception that tries to load the error page.
    How to prevent it?
    1 - if you are going to forward or redirect from a jsp page do it as early as possible in the page to prevent the buffer filling up.
    2 - just because you issued a <jsp:forward> doesn't necessarily mean the page has stopped executing. Put it in an if/else block or similar so that after it does the forward/redirect it doesn't keep executing that same page.

  • Customising Standard Oracle Package - Very Urgent

    Hi,
    We are in the process of Customising our Quotes Module.
    we have a situation where we need to have a customization in the way the template is added to the quote,
    And for this change we are need to customise an Existing Oracle Standard Database (Package) Procedure (ASO_QUOTE_PUB_W) Add_Templates_To_Quote.
    Is there any document on customising standard database procedure ?
    The alternative way may be to create a custom procedure and hence need to update the addTemplate API in the Quote class (which seems to be a roundabout way..)
    Can anyone help on this ?
    Thanks in Advance
    Senthil

    What we have decided upon is, Create a custom package with this customized procedure. And then create a new Quote class extending the Oracle Standard Quote class, this new Quote class will have the overloaded function to call the new Package-Procedure.
    i was just wondering about the deployment of this new pkg-proc, are these database objects compiled in apps schema ? i dont think so, but just got a doubt..
    Basically, its the Quotes Module. When creating the quote from a template, now the user can give number of times the template has to be applied and this multiplier has to be applied to the Quote Lines Quantity.
    Since, this addition of Quote Lines from Template to Quote is happening at the package, we will just apply the multiplier value to the Qty column of the Quote Line Record Type in the package, so that the standard package does the saving.
    We tried such an experimental change, and after this addition , the page time out. when we removed the extra 1 line of code, the screen seems to be working.
    The extra 1 line is just like
    l_qot_line_type.quantity = l_qot_line_type.quantity * p_multiplier
    thats all.
    What could be wrong ?

  • Error running...VERY URGENT, PLEASE

    Hi everyBody.
    I am programming a GUI with NetBeans 4.1, which uses javax.comm API to use serial port of computer. I have finished my GUI and it always run OK when I use NetBeans. I installed properly the API and I selected the API to be used also in NetBeans. Then I created a .jar file to run the program, but when I run it out of NetBeans, i get this interruption:
    java.lang.NoClassDefFoundError: javax/comm/PortInUseException
    at my_pirene_editor.Initial$8.run(Initial.java:928)
    at java.awt.event.InvocationEvent.dispatch(Unknown Source)
    at java.awt.EventQueue.dispatchEvent(Unknown Source)
    at java.awt.EventdispatchThread.pumpOneEventForHierarchy
    at java.awt.EventdispatchThread.pumpEventsForHierarchy
    at java.awt.EventdispatchThread.pumpEvents (unknown Source)
    at java.awt.EventdispatchThread.pumpEvents (unknown Source)
    at java.awt.EventdispatchThread.run(unknown Source)
    Please, any help to solve this problem!!!
    Thank you very much

    Make sure the Java Communications API JAR file(s) are in the CLASSPATH when you run outside of NetBeans.
    - Saish

  • Error Pl help-Very urgent!

    Am getting the following error.Please help very urgent
    500 Translator.CompilationFailedExceptionCompiler errors:
    Found 1 semantic error compiling "D:/JRun4/servers/default/default-ear/default-war/WEB-INF/jsp/jrun__quicklinks2ejspf.java":
    502. for (Enumeration e = prioLinkBean.getGlobalTop() ; e.hasMoreElements() ;)
    <---------->
    *** Error: "prioLinkBean" is either a misplaced package name or a non-existent entity.
    Translator.CompilationFailedExceptionCompiler errors:
    Found 1 semantic error compiling "D:/JRun4/servers/default/default-ear/default-war/WEB-INF/jsp/jrun__quicklinks2ejspf.java":
    502. for (Enumeration e = prioLinkBean.getGlobalTop() ; e.hasMoreElements() ;)
    <---------->
    *** Error: "prioLinkBean" is either a misplaced package name or a non-existent entity.

    prioLinkBean.getGlobalTop();
    are u sure this method returns an Enumeration ???
    post ur code!
    [email protected]

  • Error while opening a module. plz help me, very urgent.

    when i try to open a module, the following error message appears on my screen.
              " no j2ee component found in d:\krisp\programs\servlets".
              i've installed bea in c: drive and my servlet program is in d: drive.
              plz help me, it's very urgent.

    Can you provide some more information? What were you doing when this happened?
              Can you post the entire error message?
              -- Rob
              WLS Blog http://dev2dev.bea.com/blog/rwoollen/

  • Very urgent: Travel Request Error in production server

    Hi All,
    While creating Travel request in production server, we are getting an error..
    Error while writing to the database PTRV_HEAD/PTRV_PERIO/Cluster TE
    Someone please help me on this. This is very urgent..
    Thanks in advance!

    Solved..by setting up trip number ranges..
    Thanks!

  • Error during GR(very very urgent)

    Hi all,
    i am using a developed program for GR.i used this program before.there was no error.but now i am facing error like
    <b>PO ordered quqntity exceeded by 18,000 EA.</b>.i am using <b>BAPI_GOODSMVT_CREATE</b> for goods transfer.
    In the selection screen, i am putting
    PO number- PO1
    material number- MAT
    GR quantity- 18,000
    delivery order-111
    i want to receive the material MAT of quantity 18,000 from that PO.initially i have ordered PO quntity as 1 lakh. Till now i have received 42,000 materials,now i try to receive 18,000 materials.but it is showing this type of error.
    This error is fired from the return parameter of that BAPI only.error having message class-M7 & error no-022
    is comming.
    i am giving my coding below.plz suggest where is the problem.it is very very urgent.recently my company has added some patches to update the SAP.is this the cause for that error.plz suggest.
    any idea will be highly appreaciated.
    Regards
    REPORT zmui001
           LINE-SIZE 140
           LINE-COUNT 65
           NO STANDARD PAGE HEADING.
    *-- DATA DECLARATION--
    *-- tables
    TABLES : ekpo,
                ekbe,
             marv.
    *--Includes
    INCLUDE : <icon>.                   " Include for Icons
    *-- Types
    TYPES : BEGIN OF t_mseg,
              ebeln LIKE ekko-ebeln,
              name1 LIKE lfa1-name1,
              lifnr LIKE lfa1-lifnr,
              eknam LIKE t024-eknam,
              mblnr LIKE mkpf-mblnr,
              matnr LIKE ekpo-matnr,
              maktx LIKE makt-maktx,
              lgort LIKE mseg-lgort,
              charg LIKE mseg-charg, "chg: 10/17/2005
              menge LIKE mseg-menge,
              budat LIKE mkpf-budat,
              bldat LIKE mkpf-bldat, " chg : 08/18/2003
              xblnr LIKE mkpf-xblnr,
              END OF t_mseg.
    DATA:  BEGIN OF t_ekbe,
              ebeln LIKE ekbe-ebeln,
              ebelp LIKE ekbe-ebelp,
              bwart LIKE ekbe-bwart,
              matnr LIKE ekbe-matnr,
              menge LIKE ekbe-menge,
              END OF t_ekbe,
              BEGIN OF t_ekpo,
              ebeln LIKE ekpo-ebeln,
              ebelp LIKE ekpo-ebelp,
              matnr LIKE ekpo-matnr,
              menge LIKE ekpo-menge,
              END OF t_ekpo.
    TYPES : BEGIN OF t_options.
            INCLUDE STRUCTURE itcpo.
    TYPES : END OF t_options.
    *--Internal tables
    DATA: BEGIN OF i_item OCCURS 50.    "Create Material Document Item
            INCLUDE STRUCTURE bapi2017_gm_item_create.
    DATA: END OF i_item .
    DATA: BEGIN OF i_return OCCURS 20.  "Return parameter
            INCLUDE STRUCTURE bapiret2.
    DATA: END OF i_return.
    DATA: BEGIN OF i_part OCCURS 0,     " Internal table for split data
            part(20),
          END OF i_part.
    DATA: BEGIN OF i_return1 OCCURS 20.  "Return parameter
            INCLUDE STRUCTURE bapiret1.
    DATA: END OF i_return1.
    *-- Work areas
    DATA: BEGIN OF wa_header .       "Material Document Header Data
            INCLUDE STRUCTURE bapi2017_gm_head_01.
    DATA: END OF wa_header .
    DATA: BEGIN OF wa_return .       "Output Structure
            INCLUDE STRUCTURE bapi2017_gm_head_ret.
    DATA: END OF wa_return .
    *-- Work areas
    DATA: wa_mseg TYPE t_mseg,
             wa_ekbe LIKE t_ekbe,
             wa_ekpo  LIKE t_ekpo,
          wa_options TYPE t_options,
           i_ekbe LIKE STANDARD TABLE OF  t_ekbe,
            i_ekbe2 LIKE STANDARD TABLE OF  t_ekbe,
           i_ekpo  LIKE STANDARD TABLE OF  t_ekpo.
    *---Variables
    DATA: v_first,         " variable to get first digit
          v_set TYPE c,
          v_found TYPE p,
          v_menge TYPE p,
          v_ebeln LIKE ekko-ebeln,
          v_lifnr LIKE ekko-lifnr,
          v_belnr LIKE ekbe-belnr,
          v_postdate LIKE mkpf-budat,
          v_bukrs LIKE marv-bukrs,
          v_datum LIKE sy-datum,
          v_lgort LIKE mard-lgort,   " Stge. location
          v_bwart LIKE mseg-bwart,   " Movement type
          v_infnr LIKE eina-infnr,   " Info record no.
          v_ltsnr LIKE eina-ltsnr.
    *---Constants
    CONSTANTS: c_comma TYPE c VALUE ',',   " For splitting data at commas
               c_01(2) TYPE c VALUE '01',  " For movement code in Bapi
               c_b     TYPE c VALUE 'B',   " For mvt. Indicator in Bapi
               c_save(4) TYPE c VALUE 'SAVE', " For button text
               c_clear(5) TYPE c VALUE 'CLEAR', " For clear button
               c_mvmt(4) TYPE c VALUE 'MVMT',
               c_ok(2)   TYPE c VALUE 'OK',
               c_error(5) TYPE c VALUE 'Error'.
    *--SELECTION SCREEN DESIGN--
    SELECTION-SCREEN BEGIN OF BLOCK blk1 WITH FRAME.
    PARAMETERS:     p_bar(75) ,  " Scanned data from barcode
                p_ebeln LIKE ekko-ebeln, " PO number
                p_matnr LIKE ekpo-matnr, " Material number
                p_menge LIKE ekpo-menge, " Quantity
               p_lifnr LIKE ekko-lifnr, " Vendor code
                p_frbnr LIKE mkpf-frbnr, " Reference doc for goods mvt
                p_status(5) TYPE c.
    SELECTION-SCREEN END OF BLOCK blk1.
    SELECTION-SCREEN PUSHBUTTON 15(10) v_save USER-COMMAND mvmt.
    SELECTION-SCREEN PUSHBUTTON 40(10) v_clear USER-COMMAND clear.
      INITIALIZATION -
    INITIALIZATION.
      v_save = c_save .
      v_clear = c_clear.
    *--AT SELECTION_SCREEN--
    AT SELECTION-SCREEN .
      IF sy-ucomm = c_clear.
        PERFORM f_clear.
      ELSE.
        IF sy-ucomm <> c_mvmt.
           if not  sy-tabix is initial and  sy-ucomm <> c_mvmt.
    *--- Extracting the data by splitting the scanned values.
          PERFORM f_get_split_data.
    *--- Validating the input data.
          PERFORM f_check_inputs.
        ELSE .
    *--- Validating the input data.
          PERFORM f_check_inputs.
    *-- Determining the posting date and period check.
          PERFORM f_get_posting_date.
    *---Post goods movement
          PERFORM f_post_receipt.
        ENDIF.
      ENDIF.
               SUBROUTINES                                               *
    *&      Form  f_check_inputs
        Validating the input parameters
    FORM f_check_inputs.
    *-- Validating material no.
      SELECT SINGLE matnr INTO p_matnr
        FROM mara
          WHERE matnr = p_matnr.
      IF sy-subrc = 4.
        p_status =  c_error.
        MESSAGE e003(zm) WITH 'Material no.'.
      ENDIF.
    *-- Validating JHT reference no.
      SELECT SINGLE ebeln
                    lifnr
                    bukrs
                    INTO (p_ebeln, v_lifnr , v_bukrs)
                    FROM ekko
            where unsez = p_unsez. chg:07072003
              WHERE ebeln = p_ebeln.
      IF sy-subrc = 4.
        p_status =  c_error.
        MESSAGE e003(zm) WITH 'Purchase order no.'.
      ENDIF.
    *-- Validating material po combination
      SELECT SINGLE *
           FROM ekpo
             WHERE ebeln = p_ebeln
               AND matnr = p_matnr.
      IF sy-subrc = 4.
        p_status =  c_error.
        MESSAGE e003(zm) WITH 'Purchase order no.' ' and Material no.'.
      ENDIF.
    *--- Checking for DO entry . (chng : 30/06/2003)
      IF  p_frbnr IS INITIAL.
        MESSAGE e018(m7) WITH 'Delivery no.'.
        p_status =  c_error.
        PERFORM f_clear.
      ENDIF.
    *-- Validating material po do combination
      SELECT SINGLE a~belnr
                    INTO v_belnr
                    FROM ekbe AS a
                      INNER JOIN mkpf AS b
                       ON   abelnr = bmblnr
                       AND agjahr = bmjahr
                      WHERE a~ebeln = ekpo-ebeln
                        AND  a~ebelp = ekpo-ebelp
                        AND  b~xblnr = p_frbnr.
      IF sy-subrc = 0.
        MESSAGE e019(zm) WITH v_belnr.
        p_status = c_error.
        PERFORM f_clear.
      ENDIF.
      p_status =  c_ok.
    ENDFORM.                    " f_check_inputs
    *&      Form  f_get_split_data
       Extracting the data by splitting the Scanned data
    FORM f_get_split_data.
    *-- Splitting the data at commas
      SPLIT p_bar AT c_comma INTO TABLE i_part.
    *-- Assigning the parts to variables.
      LOOP AT i_part.
        v_first = i_part-part+0(1).
        TRANSLATE  v_first TO UPPER CASE.
        CASE v_first .
         WHEN 'V'.
           p_lifnr =  i_part-part+1(10).
          WHEN 'P'.
            p_matnr = i_part-part+1(18).
          WHEN 'Q'.
            p_menge = i_part-part+1(13).
          WHEN 'K'.
            p_ebeln = i_part-part+1(10).
          WHEN 'D'.
            p_frbnr = i_part-part+2(16).
          WHEN OTHERS.
            CONTINUE.
        ENDCASE.
      ENDLOOP.
    ENDFORM.                    " f_get_split_data
    *&      Form  f_get_posting_date
    Determing the posting date for document
    FORM f_get_posting_date.
    *-- get the current period for todays date.
      DATA: l_period LIKE t009b-poper.
      CALL FUNCTION 'DATE_TO_PERIOD_CONVERT'
        EXPORTING
          i_date               = sy-datum
          i_periv              = 'K4'
       IMPORTING
         e_buper               = l_period
      E_GJAHR              =
       EXCEPTIONS
         input_false          = 1
         t009_notfound        = 2
         t009b_notfound       = 3
         OTHERS               = 4
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
    *-- Determining whether the open period
      SELECT SINGLE *
                    FROM marv
                    WHERE bukrs = v_bukrs.
      IF sy-subrc = 0.
        IF l_period = marv-lfmon .
          v_postdate = sy-datum.
        ELSE.
          CALL FUNCTION 'BAPI_CCODE_GET_FIRSTDAY_PERIOD'
               EXPORTING
                    companycodeid       = v_bukrs
                    fiscal_period       = marv-lfmon
                    fiscal_year         = marv-lfgja
               IMPORTING
                    first_day_of_period = v_postdate
                    return              = i_return1.
          IF NOT i_return[] IS INITIAL.
            LOOP AT i_return1.
              MESSAGE i016(zm) WITH i_return-message.
            ENDLOOP.
          ENDIF.
        ENDIF.
      ENDIF.
    ENDFORM.                    " f_get_posting_date
    *&      Form  f_post_receipt
    Post the goods receipt for entered data.
    FORM f_post_receipt.
      PERFORM f_fill_item.
      PERFORM f_fill_header.
      PERFORM f_execute_transfer.
      PERFORM f_clear.
    ENDFORM.                    " f_post_receipt
    *&      Form  f_fill_item
      Updating the item data for the GR
    FORM f_fill_item.
    Checking for IQC cycle is done here.(chng : 23/07/2003)
      PERFORM f_check_iqc.
    *---- Assigning movement type as per IQC cycle.(chng : 23/07/2003)
      IF v_lgort IS INITIAL.
        MOVE '101'   TO i_item-move_type.
        SELECT SINGLE lgort INTO i_item-stge_loc
        FROM ekpo
         where ebeln  = v_ebeln and  " chg :07/07/2003
           WHERE ebeln  = p_ebeln AND
               matnr = p_matnr .
      ELSE.
        MOVE v_lgort TO i_item-stge_loc.
        MOVE v_bwart TO i_item-move_type.
      ENDIF.
      MOVE p_matnr TO i_item-material.
      MOVE p_menge TO i_item-entry_qnt.
    move v_ebeln to i_item-po_number. " 07/07/2003
      MOVE p_ebeln TO i_item-po_number.
      MOVE v_lifnr TO i_item-vendor.
      MOVE c_b TO i_item-mvt_ind.
    select single ebelp into i_item-po_item " chg :29/07/2003
       from ekpo
          where ebeln  = p_ebeln
            and   matnr = p_matnr
           and elikz = ''.
      SELECT ebeln
                ebelp
                matnr
                menge
                INTO CORRESPONDING FIELDS OF TABLE i_ekpo
                FROM ekpo
                WHERE ebeln = p_ebeln
                   AND matnr = p_matnr
                   AND loekz = '' .
      SORT i_ekpo BY ebeln ebelp matnr.
      LOOP AT i_ekpo INTO wa_ekpo.
        IF v_found = 0.
          SELECT ebeln  ebelp
                bwart  menge
                INTO CORRESPONDING FIELDS OF TABLE i_ekbe
                FROM ekbe
                WHERE ebeln = p_ebeln
                AND ebelp = wa_ekpo-ebelp
                AND matnr = p_matnr.
                          and elikz = '' .  CHG -- 03/19/2004
          IF sy-subrc = 0.
            LOOP AT i_ekbe INTO wa_ekbe .
              IF wa_ekbe-bwart = '101'.
                v_menge = v_menge + wa_ekbe-menge.
              ENDIF.
              IF wa_ekbe-bwart = '102'.
                v_menge = v_menge - wa_ekbe-menge.
              ENDIF.
              IF wa_ekbe-bwart = '122'.
                v_menge = v_menge - wa_ekbe-menge.
              ENDIF.
            ENDLOOP.
    chng: 03/19/2004 compare po qty against receipt
            v_menge = v_menge + p_menge .
            IF wa_ekpo-menge >= v_menge .
              v_found = 1.
              MOVE wa_ekpo-ebelp TO i_item-po_item.
            ENDIF.
          ELSE .
            v_found = 1.
            MOVE wa_ekpo-ebelp TO i_item-po_item.
          ENDIF.
        ENDIF.
        CLEAR : wa_ekbe, i_ekbe, v_menge.
      ENDLOOP.
      IF v_found = 0 .
        MESSAGE e003(zm) WITH ' delivery items'.
      ENDIF.
      APPEND i_item.
      CLEAR : i_item, v_found .
    ENDFORM.                    " f_fill_item
    *&      Form  f_check_iqc
    Checking the storage location for the (chng : 23/07/2003)
    FORM f_check_iqc.
      CALL FUNCTION 'Z_M_GET_IQC_STATUS'
           EXPORTING
                matnr          = p_matnr
                lifnr          = v_lifnr
           IMPORTING
                lgort          = v_lgort
                bwart          = v_bwart
                ltsnr          = v_ltsnr
                infnr          = v_infnr
           EXCEPTIONS
                non_iqc_vendor = 1
                OTHERS         = 2.
      IF sy-subrc <> 0.
        CLEAR : v_lgort , v_bwart , v_ltsnr.
      ENDIF.
    ENDFORM.                    " f_check_iqc
    *&      Form  f_fill_header
      Updating data in the header
    FORM f_fill_header.
      MOVE v_postdate TO wa_header-pstng_date.
      MOVE sy-datum TO wa_header-doc_date.
      MOVE p_frbnr TO wa_header-ref_doc_no.
    ENDFORM.                    " f_fill_header
    *&      Form  f_execute_transfer
          Executing the goods movement.
    FORM f_execute_transfer.
      CALL FUNCTION 'BAPI_GOODSMVT_CREATE'
           EXPORTING
                goodsmvt_header  = wa_header
                goodsmvt_code    = c_01
           IMPORTING
                goodsmvt_headret = wa_return
           TABLES
                goodsmvt_item    = i_item
                return           = i_return.
      IF i_return[] IS INITIAL .
        COMMIT WORK.
    *---  UPdating Info record for IQC cycle ind.(chng : 23/07/2003)
        IF NOT v_ltsnr IS INITIAL.
          UPDATE eina SET ltsnr = v_ltsnr
          WHERE infnr = v_infnr.
        ENDIF.
        REFRESH : i_item.
        CLEAR : wa_header,v_ltsnr , v_infnr,v_bwart,v_lifnr.
        MESSAGE i012(migo) WITH wa_return-mat_doc.
        PERFORM f_do_print.
      ELSE.
        REFRESH : i_item.
        CLEAR : wa_header,v_ltsnr , v_infnr,v_bwart,v_lifnr.
        PERFORM write_errors.
      ENDIF.
    ENDFORM.                    " f_execute_transfer
    FORM write_errors.
      WRITE: 0(90) sy-uline ,
             /0'|',
              3 'System messages for GR posting',
              90 '|',
             /0(90) sy-uline .
      LOOP AT i_return.
        CASE  i_return-type.
          WHEN 'E'.
            MESSAGE i016(zm) WITH i_return-message.
          WHEN 'W'.
            MESSAGE i017(zm) WITH i_return-message.
          WHEN 'I'.
           WRITE: /0'|',
                  icon_yellow_light AS ICON ,
                  '|',
                  10 i_return-message,
                  90 '|'.
            MESSAGE i018(zm) WITH i_return-message.
          WHEN 'S'.
           WRITE: /0'|',
                  icon_green_light AS ICON ,
                  '|',
                  10 i_return-message,
                  90 '|'.
            MESSAGE i018(zm) WITH i_return-message.
          WHEN OTHERS.
           WRITE: /0'|',
                  icon_red_light AS ICON ,
                  '|',
                  10 i_return-message,
                  90 '|'.
            MESSAGE e016(zm) WITH i_return-message.
        ENDCASE.
       AT LAST .
         WRITE:/0(90) sy-uline .
       ENDAT.
      ENDLOOP.
    ENDFORM.                    " write_errors
    *&      Form  f_clear
    Clearing the input parameters
    FORM f_clear.
      CLEAR : p_ebeln ,
              p_bar,
              p_matnr,
              p_frbnr,
              v_lifnr,
              p_menge,
              p_status.

    Hi all,
    can anyone suggest any idea?
    Regrds
    pabitra

  • Error in Personnel Data Iview (its very urgent)

    Hi All,
    Personal Data   
    Critical Error
    A critical error has occured. Processing of the service had to be terminated. Unsaved data has been lost.
    Please contact your system administrator.
    failed to create or init instance of model 'com.sap.xss.hr.per.in.pdata.model.HRXSS_PER_P0002_IN' in scope APPLICATION_SCOPE with instanceId 'null'   
    Caused by: com.sap.tc.webdynpro.progmodel.model.api.WDModelException: failed to create instance of model 'com.sap.xss.hr.per.in.pdata.model.HRXSS_PER_P0002_IN'
         at com.sap.tc.webdynpro.progmodel.model.api.WDModelFactory.getNewModelInstance(WDModelFactory.java:392)
         at com.sap.tc.webdynpro.progmodel.model.api.WDModelFactory.getOrCreateModelInstanceFromScopeMaintainer(WDModelFactory.java:329)
         ... 65 more
    Caused by: com.sap.tc.webdynpro.services.exceptions.WDRuntimeException: no jcoMetadata found for RFC function 'HRXSS_PER_GET_F4_P0002_IN'! Please verify, that your model is consistent with the ABAP backend: 'EC6'.
    Hi Please help me to solve this error it's very urgent ?
    thanks and regards,
    Phanikumar.

    Hi,
    I am not very much sure about this.
    Are u calling a BAPi from WD application?
    If yes then the error seems to be that : JCOs metadata is not available.
    Please check that ur JCO definitions in portal and make sure the name in Portal and the name u defined in WD application are same( case  sensitive).
    Also TEST JCO in Portal.
    Please revert back with current status and explain ur problem a bit more.
    Regards,
    Sumit

Maybe you are looking for

  • Best way to implement this code in labview

    Hi What is the best way to implement this code in labview programming. I have an analogue input which triggers a boolean light when it reaches a certain voltage. but at the same time i would like it to enable two other outputs one for a set period of

  • FM for download in ECC

    Hi Experts, Is there any FM available for downloading from desktop to internal table <b>which takes filename in the runtime?</b> i don't want to give value for filename parameter...Just like 'DOWNLOAD' in lower versions Regards

  • My phone number was added to someone els's iPad and it says they are using my number for iMessage

    My phone number was added to someone els's iPad and it says they are using my number for iMessage

  • Transport Request Documentation

    When any object developed in Development system then it ask for transport request which come in pop-up window. After creating transport request is it any way to make documentation mandatory for the transport request. For Ex. when we release a task it

  • Recently long press isn't an option on the screen

    First noticed it today when trying to copy a text message, works in Kindle only that I can tell, not on web pages, it will copy the url, but nothing from web text on site pages.....I'm not sure when it quit, just noticed it the last couple of days.