Field and table names requested for BAPI_INCOMINGINVOICE_CREATE

Hi all,
The following data is being hardcoded in BAPI_INCOMINGINVOICE_CREATE functional module for testing the functioning of this bapi.  Now kindly suggest me how to make this BAPI useful for all PO's.  the following data is being passed into BAPI for generation of invoice.  Kindly provide technical names along with table names for the following fields. 
HEADERDATA
        INVOICE_IND                    X
        DOC_TYPE                       RE
        DOC_DATE                       24.07.2007
        PSTNG_DATE                   24.07.2007
        REF_DOC_NO                   5000000940
        COMP_CODE                    ACW
        CURRENCY                       INR
        GROSS_AMOUNT             33,750.0000
        CALC_TAX_IND                  X
        BLINE_DATE                     24.07.2007
iTEM DATA
     INVOICE_DOC_ITEM               000001
     PO_NUMBER                         10070100
     PO_ITEM                                00001
     TAX_CODE                             V0
     ITEM_AMOUNT                       33,750.0000
     SHEET_NO                             1000002022
     ITEM_TEXT                              SDFDS
     SHEET_ITEM                           0000000001
Thanx in advance.
Krishna

Hi I have taken particular PO and Executed the code. It is generating the Invoice Document No. Now it want to remove all the Hardcoding. Code i have used is as follows. How do i remove the hardcoding ?? send meif sample code is available???
Internal table declaration *
DATA: gt_headerdata TYPE STANDARD TABLE OF bapi_incinv_create_header
INITIAL SIZE 0,
gt_itemdata TYPE STANDARD TABLE OF bapi_incinv_create_item
INITIAL SIZE 0,
gt_accountingdata TYPE STANDARD TABLE OF bapi_incinv_create_account
INITIAL SIZE 0,
gt_return TYPE STANDARD TABLE OF bapiret2
INITIAL SIZE 0.
DATA: gs_headerdata LIKE bapi_incinv_create_header.
DATA: gs_itemdata LIKE bapi_incinv_create_item.
DATA: gs_accountingdata TYPE bapi_incinv_create_account.
DATA: gs_return TYPE bapiret2.
DATA: l_date TYPE sy-datum.
l_date = sy-datum - 15.
Error flag *
DATA: l_errflag(1) TYPE c.
Build Invoice header
Document Type (Invoice)
gs_headerdata-invoice_ind = 'X'.
gs_headerdata-doc_type = 51.
Document Date
gs_headerdata-doc_date = l_date.
Posting Date
gs_headerdata-pstng_date = l_date.
Reference Document No
gs_headerdata-ref_doc_no = 323348.
gs_headerdata-gross_amount = 31.
Currency
gs_headerdata-currency = 'USD'.
Company Code
gs_headerdata-comp_code = 'D3'.
Baseline Date
gs_headerdata-bline_date = l_date.
**Tax Indicator
*gs_headerdata-calc_tax_ind = 'X'.
Build order item(s) - Only 1 is used in this example
Document Item
gs_itemdata-invoice_doc_item = 000001.
Purchase Order Number
gs_itemdata-po_number = 3700000011.
Purchase Order Item
gs_itemdata-po_item = 00010.
Quantity
gs_itemdata-quantity = 31.
gs_itemdata-po_unit = 'Z00'.
Item Amount
gs_itemdata-item_amount = 31.
gs_itemdata-tax_code = 'O0'.
gs_itemdata-taxjurcode = '0100000000'.
APPEND gs_itemdata TO gt_itemdata.
Document Item
*gs_itemdata-invoice_doc_item = '00002'.
Purchase Order Number
*gs_itemdata-po_number = '4700000158'.
Purchase Order Item
*gs_itemdata-po_item ='00020' .
Quantity
*gs_itemdata-quantity = '5'.
*gs_itemdata-po_unit = 'Z00'.
Item Amount
*gs_itemdata-item_amount = '5'.
*gs_itemdata-tax_code = 'O0'.
*gs_itemdata-taxjurcode = '0100000000'.
*APPEND gs_itemdata TO gt_itemdata.
Accounting Data
***gs_accountingdata-costcenter = 'DUMMY CCTR'.
*gs_accountingdata-invoice_doc_item = '00001'.
*gs_accountingdata-xunpl = 'X'.
*gs_accountingdata-tax_code = 'O0'.
*gs_accountingdata-taxjurcode = '0100000000'.
*gs_accountingdata-ITEM_AMOUNT = 100.
*gs_accountingdata-gl_account = '0003805101'.
*APPEND gs_accountingdata TO gt_accountingdata.
*CLEAR :gs_accountingdata.
*Call the BAPI to Create the Return Order
data: gv_INVOICE type BAPI_INCINV_FLD-INV_DOC_NO,
gv_YEAR type BAPI_INCINV_FLD-FISC_YEAR.
CALL FUNCTION 'BAPI_INCOMINGINVOICE_CREATE'
EXPORTING
headerdata = gs_headerdata
IMPORTING
INVOICEDOCNUMBER = gv_INVOICE
FISCALYEAR = gv_YEAR
TABLES
return = gt_return
itemdata = gt_itemdata.
accountingdata = gt_accountingdata.
PERFORM error.
Check and write Return table
FORM error.
LEAVE TO LIST-PROCESSING.
CLEAR l_errflag.
LOOP AT gt_return INTO gs_return.
WRITE: / gs_return-type, gs_return-message(200).
IF gs_return-type = 'E'.
l_errflag = 'X'.
ENDIF.
ENDLOOP.
PERFORM commit.
ENDFORM. " ERROR INPUT
No errors - Commit
FORM commit.
IF l_errflag IS INITIAL.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
ENDIF.
ENDFORM. " COMMIT INPUT
Thanks in advance
Krishnasri

Similar Messages

  • Field  and Table name for purchaser

    I want to know the field and table name for purchaser id and purchaser name.
    Plz help me.

    Dear
    Purchaser name are define in Header level data in Purchase Order EKKO & Purchase ID define as a Purchasing Group
    Purchser Name EKKO-ERNAM
    Purchase I D  EKKO-EKGRP
    Regards
    Aamir

  • Want field and table name for RESERVED coloum in MMBE

    Hi ,
            There is a RESERVED coloum in MMBE and     I want this   * RESERVED* coloum  in  MB52   .
           I got to know that Field related to this  RESERVED coloum is BDMNG coming from table RESB .
           To confirm the field and table I checked the value in BDMNG by putting join on MARA and RESB where MATNR = BAUGR.
            But I got  value in BDMNG is 50 and in MMBE it is .228 for that material.
               Please tell me field and table name for RESERVED coloum. and hoe to join MARA and RESB  to get exact result.
    Thanks and Regards,
    Ranu

    Hi,
    Mara-matnr is not equal to Resb-matnr and it shows no record if i do like this.
    But Mara-matnr is equal to Resb-baugr, and it gives me 1 record .But porblem is that i dint get BDMNG field matching with mmbe RESEVERD coloum.

  • Purchase Order released date field and table name

    Hi,
    Please tell me the  Purchase Order released date field and table name.
    Regards
    Deepak

    Hi,
    Table : EKKO.
    Fields : FRGKE,FRGZU.
    You can get release date of PO from CDHDR  table.
    give object value as your po number and check.dont forget to give leading zeros.
    The udate will be date field and transaction will be me29n for relaesed po.

  • What is the field and table name to describe -Employee Hourly Rate or Emplo

    Hi,
    Can any one please tell me what is the field and table name to describe 
    Employee Hourly Rate or Employee Rate.
    Thanks for ur time.
    Murali.

    Hi Murali,
    The hourly rate is tied to a Wagetype & maintained in Infotype 0008. The database table is PA0008.
    the field could vary depending on the No of wagetypes maintained.
    regards,
    Suresh Datti

  • Reg:field and table name

    Hi Guys,
    I am developing one report for knowing the recognised amount ,but i am not able to get the field and table name .In system it is showing that VBRAV51HD:RVAMT_REAL_G.But this is a structure,how to get a field name for recognised amount.Please help.
    Thanks & Regards,
    Sash.

    Hi sash,
    I think u need to some R n D upon it. First take the structure and open it in SE11. Then try to find out what all tables does the structure comprises of. Then try finding the relevant fieldname of the table( which is also existent in the structure) getting accessed when the field is triggered. That may solve your problem. try finding the objective of your structure being shown.
    Abhijit

  • Cost Component structure field and table names

    Hey all,
    i need to code a BADI to push value of one column in cost component structure to another column in ccs for only order settlements..
    any idea how to do this??
    i am very new to abap please take it easy on ur answer..
    i coulndt even find in which table and fields these values are stored...
    thank you

    I have an OSS note, it tells you step by step how to config the badi u need.. but does not mention about the logic u ll use.. it is up to you....
    so i need to find the field names and tell take these and post them to these columns...
    i dont know if i make any sence, but this is all i need to do...
    so i have the body i have the logic but i dunno the import and export fields...
    i believe the table is ckmlkeph.... and field that populate the columns are kst0XX, but i cannot see the field name and table name if i select a line in the column and F1 ????

  • Access migration - handling really silly field and table names

    Hi All,
    I'm working through migrating an ** interesting ** Access database that has been hacked together over the years by a number of ... talented amateurs.
    I've noticed a difference in the way the migration wizard translates some of the really silly names it's got, between creating the table script and creating view scripts.
    It seems to manage the silliness better when creating the tables, but it doesn't quite catch up when creating the views.
    For example the main table in this application is called (believe it or not):
    "T - This Appn Detail - MAIN TABLE"
    Note that it's 33 characters long as well as including spaces and hyphens.
    The table creation script creates a table called T___This Appn_Detail___MAIN_TA (which works)
    But the translation of a query off this table to a view is looking for a table named T___This Appn_Detail___MAIN_TABL
    Which is (a) different and (b) too long
    It does a similar thing with our exciting field names. We have a field in the Access database called "Net Rate (twin share)"
    The table script calls this "Net Rate _twin share_" but the view script sticks with "Net Rate (twin share)" - which causes "FROM keyword not found where expected"
    Does anyone know if there's a way to nudge the view creation process in the right direction?
    I guess the most sensible thing is to go into Access and correct the field names, but I don't want to spend a great deal of time updating the Access database so all the references to the fields get fixed, when I'm about to ditch it anyway.
    Thanks,
    Greg H

    Hi Greg,
    The Access SQL translator should be referencing the SQL Developer Migration Workbench repository to find the correct migrated name of your tables, columns. Thereby producing PL/SQL which references the correct table name. :(
    I have logged this as a bug to be fixed in our next release.
    6647344: ACCESS VIEW TRANSLATION REFERENCES OLD OR INCORRECT TABLE NAMES
    I can try and replicate your issues as described, but would it be possible for you to send in your access databases so we can test it here?
    You may delete the data if you wish, its the schema of the database I'm interested in.
    Unfortunately this is not an offer to complete the migration :)
    But it would better help us understand the exact issues you are experiencing and help us better our product.
    Thanks
    Dermot.
    Message was edited by:
    dooneill

  • How can find  database field and table name

    how can find the underline database field name,table name from java page. Example. in oracle apps when we go purchaseing super user then supplier base then supplier and find supplier detail .

    Hi,
    depends on your model. If you work with ADF BC then you can use ViewLinks to access parent or detail infromation programmatically. See the developer guides for more information. Note that you wont access the tables directly but the collections that represent the records
    Frank

  • R3 field and table names

    Could someone kindly tell me where in BW I can find reference to the correspnding R3 field name and table.
    Thanks & regards
    Tina

    To find the table where the field exists  -Easy ways first check for the datasources at http://help.sap.com/saphelp_nw2004s/helpdata/en/3d/5fb13cd0500255e10000000a114084/frameset.htm as Rasim suggested.
    If that really doesn't help you have to have a look at this Excellent blog by Roberto Negro : /people/sap.user72/blog/2005/09/05/sap-bw-and-business-content-datasources-in-pursuit-of-the-origins
    You can run a trace in ST05 with RSA3 on n check wot tables is d datasource reading.

  • Field and table names.

    Problem solved.
    Edited by: saad A on May 15, 2008 8:27 PM

    Hello,
    Look at SE16 transparent tables DD03T and DD03L. Here you can find the information thatt you need.
    Regards,

  • FIELD AND TABLE NAME

    in VL31N  Tcode........
    when creating a ASN...its created prior to the qty available for a part no( ie  qty released)
    in some conditions the invoice qty will be more than scheduled qty....
    so i want to compare both qty's.....
    i got the invoice qty's....but where from can i get the balanced reduced qty of a material.
    i checked in EKEH and EKET...but bit confused...
    can anybody tell the correct route to pick the balance qty

    Thats the storage location qty....but i nedd the qty thats released for a PO ar SA.
    example:the default qty that apperars in VL31N against a material.

  • Where can i get   SALES  ORGANIZATION    FIELD and TABLE

    Can anybody tell me   where can i get   FIELD  and   TABLE  Name   OF  " sales organization    "

    Dear Sandeep,
    u will find VKORG is the Sales Organisation .
    u will find this Field in every related SD Module Table...
    Like ...VBAP,BKPF ..etc..
    Hope it helps...!!!
    Pls reward if Helpful...!!!

  • Field and Table for Pension Plan

    Can anyone tell me what are the field name and table name in Pension plan

    Hi Harini,
    In Table VBUK you 3 different status related fields for  sales documents.
    Over all status field name GBSTK ( here it gives the total status of praticular sales document) here you see options
    A  Not yet processed      ( This means its complete open)
    B  Partially processed     ( This means the sales doc is partially processed)
    C  Completely processed  ( This means the sales doc is completly processed)
    Delivery status  and over all delivery status field name LFSTK and LFGSK respectively, these 2 fields will be same always ( here it gives the total status of praticular sales document) here you see options
    A  Not yet processed      ( This means its completly  open)
    B  Partially processed     ( This means the delivery doc is partially processed)
    C  Completely processed  ( This means the delivery doc is completly processed)
    So overall status can be  different then delivery or overall delivery status.
    If sales document has 100 quantity for 1 material, if delivery is done for 50 quantity.
    Then over all status field name GBSTK will be B  Partially processed and delivery and overall delivery will be C  Completely processed  .
    Regards
    vK

  • Field and Table for PGI status updation

    Hi All,
    I want to know in which field and table the PGI status will get updated.
    i.e. once we do the PGI for a delivery in which table will this PGI status gets updated.
    Thanks in advance for help.
    Harini

    Hi Harini,
    In Table VBUK you 3 different status related fields for  sales documents.
    Over all status field name GBSTK ( here it gives the total status of praticular sales document) here you see options
    A  Not yet processed      ( This means its complete open)
    B  Partially processed     ( This means the sales doc is partially processed)
    C  Completely processed  ( This means the sales doc is completly processed)
    Delivery status  and over all delivery status field name LFSTK and LFGSK respectively, these 2 fields will be same always ( here it gives the total status of praticular sales document) here you see options
    A  Not yet processed      ( This means its completly  open)
    B  Partially processed     ( This means the delivery doc is partially processed)
    C  Completely processed  ( This means the delivery doc is completly processed)
    So overall status can be  different then delivery or overall delivery status.
    If sales document has 100 quantity for 1 material, if delivery is done for 50 quantity.
    Then over all status field name GBSTK will be B  Partially processed and delivery and overall delivery will be C  Completely processed  .
    Regards
    vK

Maybe you are looking for