How to get custom field value in vbkd table using "SD_SALESDOCUMENT_CREATE" bapi

Hi Experts,
Need your help . In one program Iam using SD_SALESDOCUMENT_CREATE bapi .
i/p for my report is am excel.
excel is having  below formatt.
To create salesdoc we are using SD_SALESDOC_CREATE bapi.
but After execution of the program we are unable to find the ZZFV_SBCNT (which is custom  field) in VBKD w.r.t salesdocument.
Need your help what we need to do to reflect the value in vbkd table.
Here temp will contains the data from excel
1)
FORM f_move_header_data .
   wg_header-doc_type            = wg_temp-auart .                   "Order type
   wg_header-sales_org           = wg_temp-vkorg .                   "Sales Organization
   wg_header-distr_chan          = wg_temp-vtweg .                   "Distribution Channel
   wg_header-division            = wg_temp-spart.                    "Division
   wg_header-sales_off           = wg_temp-vkbur .                   "Sales Office
   wg_header-sales_grp           = wg_temp-vkgrp .                   "Sales Group
   wg_header-purch_no_c          = wg_temp-bstnk .                   "Customer purchase order number
   wg_header-pymt_meth           = wg_temp-zlsch  .                  "Payment Method
   wg_header-zzychan_role        = wg_temp-zzychan_role_i.           "Channel Role
   wg_header-zzysub_role         = wg_temp-zzysub_role  .            "Submitter Role
   wg_header-zzy_inv_for_opt     = wg_temp-zzinv_format  .           "Invoice Format Optio
   wg_header-ord_reason          = wg_temp-augru  .                  "Order Reason Code
   wg_header-bill_block          = wg_temp-faksp.                    "Billing Block
   wg_headerx-doc_type            = c_set .                   "Order type
   wg_headerx-sales_org           = c_set .                   "Sales Organization
   wg_headerx-distr_chan          = c_set .                   "Distribution Channel
   wg_headerx-division            = c_set.                    "Division
   wg_headerx-sales_off           = c_set .                   "Sales Office
   wg_headerx-sales_grp           = c_set .                   "Sales Group
   wg_headerx-purch_no_c          = c_set .                   "Customer purchase order number
   wg_headerx-pymt_meth           = c_set  .                  "Payment Method
   wg_headerx-zzychan_role        = c_set.                    "Channel Role
   wg_headerx-zzysub_role         = c_set .                   "Submitter Role
   wg_headerx-zzy_inv_for_opt     = c_set .                   "Invoice Format Option
   wg_headerx-ord_reason          = c_set .                   "Order Reason Code
   wg_headerx-bill_block           = c_set.                    "Billing Block
ENDFORM.                    " F_MOVE_HEADER_DATA
2)
FORM f_move_item_data .
   wg_item-itm_number          =   g_itmnumber.                              "Item number
   wg_item-material            =   wg_process-matnr .                        "Material
   wg_item-target_qty          =   wg_process-target_qty.                    "Targeted Qty
   wg_item-item_categ          =   wg_process-pstyv.                         "Sales document item category
   wg_item-zzylegal_i          =   wg_process-zzlegal.                       "Legal Contract
**********Added this line for vbkd-ZZFV_SBCNT****************************
   wg_item-zzfv_sbcnt          = wg_process-zzfv_sbcnt.      
APPEND wg_item TO i_item.
wg_itemx-material            =   c_set .                        "Material
   wg_itemx-target_qty          =   c_set.                         "Targeted Qty
   wg_itemx-item_categ          =   c_set.                         "Sales document item category
   wg_itemx-zzylegal_i          =   c_set.                         "Legal Contract
   wg_itemx-zzsteady_date       =   c_set .                        "Amortization Start Date
   wg_itemx-zzsteady_end_dat    =   c_set.                         "Amortization Stop Date
**********Added this line for vbkd-ZZFV_SBCNT****************************
   wg_itemx-ZZFV_SBCNt     =   c_set.   "
   APPEND wg_itemx TO i_itemx.
   CLEAR : wg_itemx. 
endform. 
3)           
FORM f_move_head_ext
wg_extension-structure   = c_ext_vbak.
   wg_ext_vbak-zzinv_format = wg_temp-zzinv_format.
wg_ext_vbak-zzychan_role = wg_temp-zzychan_role_i.
   wg_ext_vbak-zzysub_role  = wg_temp-zzysub_role.
   wg_extension+30 = wg_ext_vbak.
APPEND wg_extension to i_extension.
CLEAR wg_extension.
   wg_extensionx-structure =  c_ext_vbakx.
   wg_ext_vbakx-zzinv_format = c_set.
  wg_ext_vbakx-zzlegal      = c_set.
   wg_ext_vbakx-zzychan_role = c_set.
   wg_ext_vbakx-zzysub_role  = c_set.
   wg_extensionx+30 = wg_ext_vbakx.
   APPEND wg_extensionx TO i_extensionx.
   CLEAR wg_extensionx.
ENDFORM.                    " F_MOVE_HEAD_EXT
*&      Form  F_MOVE_ITEM_EXT
*       Item Extension
4)
FORM f_move_item_ext .
* Structure for BAPI parameter Extension
   wg_extension-structure = c_ext_vbap.
   wg_ext_vbap-posnr      = g_itmnumber.
   wg_ext_vbap-zzsteady_date       =   wg_process-zzsteady_date .                 "Amortization Start Date
   wg_ext_vbap-zzsteady_end_dat    =   wg_process-zzsteady_end_dat.               "Amortization Stop Date
   wg_ext_vbap-zzlegal             =   wg_process-zzlegal.                        "Legal Contract
   wg_extension+30 = wg_ext_vbap.
APPEND wg_extension to i_extension.
* Structure for BAPI parameter Extension - Update Indicator Fields
   wg_extensionx-structure =  c_ext_vbapx.
   wg_ext_vbapx-posnr = g_itmnumber.
   wg_ext_vbapx-zzsteady_date       =   c_set .
   wg_ext_vbapx-zzsteady_end_dat    =   c_set.
*  wg_ext_vbapx-zzlegal             =   c_set.
*wg_process-zzfv_sbcnt = c_set.
   wg_extensionx+30 = wg_ext_vbapx.
   APPEND wg_extensionx TO i_extensionx.
   CLEAR wg_extensionx.
and bapi calling is like below.
CALL FUNCTION 'SD_SALESDOCUMENT_CREATE'
     EXPORTING
       sales_header_in       = wg_header
       sales_header_inx      = wg_headerx
       logic_switch          = wg_logic_switch
       business_object       = fp_bus_obj
       status_buffer_refresh = 'X'
     IMPORTING
       salesdocument_ex      = g_sorder
     TABLES
      return                = i_return
       sales_items_in        = i_item
       sales_items_inx       = i_itemx
       sales_partners        = i_partner
       sales_conditions_in   = i_cond
       sales_conditions_inx  = i_condx
       sales_text            = i_text
       extensionin           = i_extension
     extensionex           = i_extensionx.
still we are not getting ZZFV_SBCNT value in VBKD table w.r.t created salesdoc(g_sorder)
Please help me from this issue.
Thank You..

Hi,
Please let me know how to add custom fields in the characteristic list, My clients wants department and profit center grouping.
Please tell me how to solve it..
Thanks & Regards,
Reena..

Similar Messages

  • How to get selected row values in a table using check box

    Hi ADF Experts,
    JDEV Version 11.1.1.7.0
    My requirement is getting the selected row valuesof a af:table using a checkbox(multi select).
    Thanks,
    Animesh

    Hi,
    add a transient attribute to the POJO entity and update this through a check box. The ensure you have autosubmit=true set on the check box. In a value change listener set or remove the row's checbox attribute value
    Frank

  • How to get item field values for old versions?

    I need to be able to query old field values from previous versions of items in a SharePoint list. I can't execute code on the server (it needs to work with SharePoint Online/O365 for a start).
    So far the ONLY API I've that lets me do this is the lists.asmx GetVersionCollection SOAP call.
    This lets me specify a single field name and returns an XML structure with the values for the various versions, along with the modification time and who made the change - but NO reliable way of actually identifying *which* version (i.e. an ID or label). That
    is, if I know I need to fetch the Title value from version 512 ("1.0") of item 1 in list "Documents", I don't see how to reliably parse the results to determine which entry is version 512. While they may be returned in order, in many cases
    the entries are actually missing when there was no field value present (or perhaps when the field hadn't been created yet). I've tried comparing the Modified date to the Created date of the corresponding FileVersion item (which I can get via CSOM or REST),
    and while it works some of the time, it's not reliable. I've also looked at the output from the lists.asmx GetVersion API but I don't see how that's useful either, as the Created property for all versions always seems to be just the date the file was originally
    created.
    It does seem odd to me that there's not a neat way of doing this - if I need to return information for several fields but just for a single version, I have to make a whole lot of requests that return far more info than I need, and then I need to figure out
    how to parse the returned text in the case of, say, multiple-value taxonomy fields etc.
    Anyone tried doing anything similar here?
    Thanks
    Dylan

    try these links:
    https://support.office.microsoft.com/en-us/article/Track-and-view-version-information-for-SharePoint-list-items-2d69d936-fb0b-4c84-830e-11708e6ec317?CorrelationId=f87cf6ea-8cbf-446a-a4a0-e2c3a86b3425&ui=en-US&rs=en-US&ad=US
    https://social.technet.microsoft.com/Forums/en-US/e48ff216-7ed1-4b20-9f21-d496b1583eea/how-to-get-item-field-values-for-old-versions?forum=sharepointdevelopment
    http://sharepoint.stackexchange.com/questions/20019/get-meta-data-from-a-previous-version-of-a-document-through-webservice-in-moss-2
    http://sharepoint.stackexchange.com/questions/121594/getting-information-from-previous-versions-of-a-sp-list-using-csom
    Please mark answer as correct if it is correct else vote for it if you find it useful Happy SharePointing

  • How to get a field value in the report

    hi all :-
    i need to get the field value in the formate trigger inside a specified field in the report?

    please post your request in the report category forum

  • How to get edited row values from ADF table?

    JDev 11.
    I have a table which is populated with data from Bean.
    I need to save changes after user make changes in any table cell. InputText is defined for table column component.
    I have defined ValueChangeListener for inputText field and AutoSubmit=true. So when user change value in inputText field, method is called:
    public void SaveMaterial(ValueChangeEvent valueChangeEvent) {
    getSelectedRow();
    SaveMaterial(material);
    This method should call getSelectedRow which take values from selected table row and save them into object:
    private Row getSelectedRow(){
    RichTable table = this.getMaterialTable();
    Iterator selection = table.getSelectedRowKeys().iterator();
    while (selection.hasNext())
    Object key = selection.next();
    table.setRowKey(key);
    Object o = table.getRowData();
    material = (MATERIAL) o;
    System.out.println("Selected Material Desc = "+material.getEnumb());
    return null;
    Problem is that getSelectedRow method doesnt get new (edited) values, old values are still used.
    I have tried to use ActiveButton with same method and it works fine in that case. New values are selected from active row and inserted into object.
    JSF:
    <af:table var="row" rowSelection="single" columnSelection="single"
    value="#{ManageWO.material}" binding="#{ManageWO.materialTable}">
    <af:column sortable="false" headerText="E-number">
    <af:inputText value="#{row.enumb}" valueChangeListener="#{ManageWO.SaveMaterial}" autoSubmit="true"/>
    </af:column>
    <af:column sortable="false" headerText="Description">
    <af:inputText value="#{row.desc}" valueChangeListener="#{ManageWO.SaveMaterial}" autoSubmit="true"/>
    </af:column>
    </af:table>
    <af:activeCommandToolbarButton text="Save" action="#{ManageWO.EditData}"/>
    What is a correct place from where save method should be called to get new (edited) values from ADF table?
    Thanks.

    Did you look into the valueChangeEvent?
    It has oldValue and newValue attributes.
    public void SaveMaterial(ValueChangeEvent valueChangeEvent) {
    Object oldVal = valueChangeEvent.getOldValue();
    Object newVal = valueChangeEvent.getNewValue();
    // check if you see what you are looking for.....
    getSelectedRow();
    SaveMaterial(material);
    }Timo

  • How to get the field names of a table

    hi all,
    i need to get all field names of a table. here i dont need any data. i need only field names.
    initially i used this query, select * from tname;
    the problem is if table have 1000 records, all records will be in memory.
    how to get this one.
    regards
    pavan.

    hi all,
    thanks a lot. the query is working.
    initially i given this query
    select column_name from user_tab_columns where table_name='mytable';
    but no rows selected.
    and i tried with this,
    select column_name from user_tab_columns where table_name='MYTABLE';
    this is working fine.
    thanks
    pavan.

  • How to get Input field value?

    Hi All,
    I have some problem in getting of input value from View to customcontroller.
    My problem is I have created a Input field in the view and if Iam giving the value to that field I can capture the value from View to customcontroller and send it as BAPI input.But My input filed is in the view Context.
    How can i capture InputFiled value from View to CustomController.
    Advance thanks
    Nageswara.
    Message was edited by: nageswar mandapati

    Thanks for your response Patrick,
    In my customcontrollerView all my BAPI mathods instances and execute methods are declared.All the attributes directly getting from model class.
    But I have two views , in first view I created a input field(for that i created valueAttribute in that context).
    Here I want give the conditions If  the input field is empty then directly call the execute method of BAPI.
    Otherwise give any input to the inputfiled then capture that value and send it input to BAPI from view to BAPI.
    In my customcontroller
    BAPI b = new BAPI();
    b.Param1();
    b.param2();
    and
    execute BAPI()
    I done like this.
    How can i capture the view input value how to send as a b.parama();
    Please guide me .
    Any snippests appriciate.
    Thanks
    nageswara.

  • How to get ip field values to itab?

    hi,
    plz tel me how to get the values of set of inputfields into ITAB.
    suppose in BSP page there are three input fields like ...
    StudetnID
    NAME
    PLACE
    After Entering the details when i click save button it has to be store in dbtable.
    Plz help me.. i am new to BSP....
    Regards,
    shankar.

    Hi Shankar,
    Try like this...
    DATA: event type ref to cl_htmlb_event.
    DATA: ip_fields type TIHTTPNVP,
          wa_fields type ihttpnvp.
    event = cl_htmlb_manager=>get_event( runtime->server->request ).
    if event->id = 'btn'.
    request->get_form_fields( changing fields = ip_fields ).
    "for stud_id
    READ TABLE ip_fields INTO wa_fields WITH KEY name = 'ip1'.
            IF sy-subrc = 0.
              MOVE: wa_fields-value TO i_id.
            ENDIF.
    "for name
    READ TABLE ip_fields INTO wa_fields WITH KEY name = 'ip2'.
            IF sy-subrc = 0.
              MOVE: wa_fields-value TO i_name.
            ENDIF.
    "for place
    READ TABLE ip_fields INTO wa_fields WITH KEY name = 'ip3'.
            IF sy-subrc = 0.
              MOVE: wa_fields-value TO i_place.
            ENDIF.
    endif.
    In layout
    <htmlb:inputField  id = 'ip1' value = '<%=i_id %>'/>
    <htmlb:inputField  id = 'ip2'  value = '<%=i_name %>'/>
    <htmlb:inputField  id = 'ip3'  value = '<%=i_place %>'/>
    Give all the values with in double quote which are all written in single quote
    Regards,
    Sri

  • How to get input text values from adf table - Urgent

    Hi Friends,
    This is my requirement. I designed customized master - detail - detail page. I customized the page in below format.
    1. Master Data Field (Input text,etc) .
    2. Detail in table format ( Rows are mapped to child table) and i given two buttons for to create row and delete row. I designed the table based on the example provided in forum for to create customized table. The input text component is mapped to the rows.
    Now i want to retrieve all the data's entered in the rows. The table is mapped to child table. When i read the values from the table its showing null.
    If any one faced this problem and fixed it, please send me the solution.
    Thanks & Regards
    VB

    Did you look into the valueChangeEvent?
    It has oldValue and newValue attributes.
    public void SaveMaterial(ValueChangeEvent valueChangeEvent) {
    Object oldVal = valueChangeEvent.getOldValue();
    Object newVal = valueChangeEvent.getNewValue();
    // check if you see what you are looking for.....
    getSelectedRow();
    SaveMaterial(material);
    }Timo

  • How to get all minimum values for a table of unique records?

    I need to get the list of minimum value records for a table which has the below structure and data
    create table emp (name varchar2(50),org varchar2(50),desig varchar2(50),salary number(10),year number(10));
    insert into emp (name,org,desig,salary,year) values ('emp1','org1','mgr',3000,2005);
    insert into emp (name,org,desig,salary,year) values ('emp1','org1','mgr',4000,2007);
    insert into emp (name,org,desig,salary,year) values ('emp1','org1','mgr',7000,2007);
    insert into emp (name,org,desig,salary,year) values ('emp1','org1','mgr',7000,2008);
    insert into emp (name,org,desig,salary,year) values ('emp1','org1','mgr',7000,2010);
    commit;
    SELECT e.name,e.org,e.desig,min(e.year) FROM emp e,(
    SELECT e1.name,e1.org,e1.desig,e1.salary FROM emp e1
    GROUP BY (e1.name,e1.org,e1.desig,e1.salary)
    HAVING COUNT(*) >1) min_query
    WHERE min_query.name = e.name AND min_query.org = e.org AND min_query.desig =e.desig
    AND min_query.salary = e.salary
    group by (e.name,e.org,e.desig);With the above query i can get the least value year where the emp has maximum salary. It will return only one record. But i want to all the records which are minimum compare to the max year value
    Required output
    emp1     org1     mgr     7000     2008
    emp1     org1     mgr     7000     2007Please help me with this..

    Frank,
    Can I write the query like this in case of duplicates?
    Definitely there would have been a better way than the query I've written.
    WITH      got_analytics     AS
         SELECT     name, org, desig, salary, year
         ,     MAX (SALARY)  OVER ( PARTITION BY  NAME, ORG, DESIG)          AS MAX_SALARY
         ,     ROW_NUMBER () OVER ( PARTITION BY  NAME, ORG, DESIG, SALARY
                                    ORDER BY        year  DESC
                           )                              AS YEAR_NUM
           FROM    (SELECT 'emp1' AS NAME, 'org1' AS ORG, 'mgr' AS DESIG, 3000 AS SALARY, 2005 AS YEAR FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',4000,2007 FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',4000,2008 FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',7000,2007 FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',7000,2007 FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',7000,2008 FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',7000,2010 FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',7000,2010 FROM DUAL)
    SELECT     name, org, desig, salary, year
    FROM     got_analytics
    WHERE     salary          = max_salary
    AND     YEAR_NUM     > 1
    Result:
    emp1     org1     mgr     7000     2010
    emp1     org1     mgr     7000     2008
    emp1     org1     mgr     7000     2007
    emp1     org1     mgr     7000     2007
    WITH      got_analytics     AS
         SELECT     name, org, desig, salary, year
         ,     MAX (SALARY)  OVER ( PARTITION BY  NAME, ORG, DESIG)          AS MAX_SALARY
         ,     ROW_NUMBER () OVER ( PARTITION BY  NAME, ORG, DESIG, SALARY
                                    ORDER BY        year  DESC
                           )                              AS YEAR_NUM
      ,     ROW_NUMBER () OVER ( PARTITION BY  NAME, ORG, DESIG, SALARY, Year
                                    ORDER BY        YEAR  DESC
                           )                              AS year_num2
         FROM    (SELECT 'emp1' AS NAME, 'org1' AS ORG, 'mgr' AS DESIG, 3000 AS SALARY, 2005 AS YEAR FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',4000,2007 FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',4000,2008 FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',7000,2007 FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',7000,2007 FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',7000,2008 FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',7000,2010 FROM DUAL UNION ALL
    SELECT 'emp1','org1','mgr',7000,2010 FROM DUAL)
    SELECT     name, org, desig, salary, year
    FROM     got_analytics
    WHERE     salary          = max_salary
    AND     YEAR_NUM     > 1
    AND YEAR_NUM2 < 2
    Result:
    emp1     org1     mgr     7000     2008
    emp1     org1     mgr     7000     2007

  • How to get a node selection in a table using Arraylist

    Hi All,
      Can someone help me with the code to get the node selected value from a table and then set that values to input fields?
    Early response would be much appreciated.
    Thanks
    Uday

    Dear Uday,
    Please user the isMultiSelected inside the for loop and iterate through all the rows selected to set in the arraylist.
    Refer to this might help: delete records from table
    if(wdContext.node<Node Name>().size()>0)
                // Iterate through the context Node
                for(int i=0;i<wdContext.node<Node Name>().size();i++)
           if(wdContext.node<Node Name>().isMultiSelected(i))  {
                      // Set the ArrayList here for the Lead Selected elements of the Table multiple selected rows
                            }else {
                                   // Set the ArrayList here for the Lead Selected elements of the Table single selected rows
    Best Regards
    Arun Jaiswal
    Edited by: Arun Jaiswal on Dec 10, 2011 2:04 PM

  • How to update specific fields of a db table using MODIFY

    Hi all.
    I understand that MODIFY allows us to insert a record into the database if the a record with the same key is not there. If a record is there, it would update that record.
    However, when the record is there, could i update SPECIFIC fields of the record, instead of updating ALL fields of the record?

    Yes, you can with exception that you can not modify primary key values.
    Here are the details about MODIFY db table command with examples
    MODIFY - Change a database table
    Variants:
    MODIFY dbtab. or   MODIFY *dbtab. or
      MODIFY (dbtabname) ... .
    MODIFY dbtab FROM TABLE itab. or   MODIFY (dbtabname) FROM TABLE itab.
    MODIFY dbtab VERSION vers. or   MODIFY *dbtab VERSION vers.
    Effect
    Inserts new lines or updates existing lines in a database table (s. relational database). If a line with the specified primary key already exists, an UPDATE is executed. Otherwise, an INSERT is performed. You can specify the name of the database table either in the program itself in the form MODIFY dbtab ... or at runtime as the contents of the field dbtabname in the form MODIFY (dbtabname) ... . In both cases, the database table must be defined in the ABAP Dictionary. If the program contains the name of the database table, it must also have a corresponding TABLES statement. Normally, records are inserted or updated only in the current client. Data can only be inserted or updated using a view, if the view refers to a single table and was created in the ABAP Dictionary with the maintenance status "No restriction".
    MODIFY belongs to the Open SQL command set.
    When the statement has been executed, the system field SY-DBCNT contains the number of edited lines.
    The Return code is set as follows:
    SY-SUBRC = 0:
        All lines were successfully inserted or updated.
    SY-SUBRC = 4:
        One or more lines could not be inserted or updated.
    Notes
       1. You cannot modify a line if there is already a line in the table with identical key field values in a UNIQUE index.
       2. Automatic definition of INSERT and UPDATE is expensive. You should therefore use MODIFY only if you cannot define the INSERT and UPDATE cases yourself in the program.
       3. Since the MODIFY statement does not perform authority checks, you have to program them yourself.
       4. Adding or changing lines with the MODIFY command is only completed after a database commit (see LUW) has been performed. Before the database commit has been performed, any database changes can be reversed with a database rollback (see Programming transactions).
       5. Synchronization of simultanous accesses by several users to the same set of data cannot be exclusively achieved with the lock mechanism of the database system. In several cases, you are recommended to use the SAP lock mechanism.
    Variant 1
    MODIFY dbtab. or
    MODIFY *dbtab. or
    MODIFY (dbtabname) ... .
    Extras:
    ... FROM wa
    ... CLIENT SPECIFIED
    See Cannot Use Short Forms and
    Cannot Use *Work Areas.
    Effect
    Inserts a new line or updates an existing line in a database table. If you specify the name of the database table yourself, the primary key for identifying the line to be inserted or updated and the relevant values are taken from the table work area dbtab or *dbtab (see TABLES). If you declare the name of the database table explicitly, the program must also contain a corresponding TABLES statement. If the name of the database table is not determined until runtime, you need to use the addition ... FROM wa.
    Example
    Insert or change data of the customer Robinson in the current client:
    TABLES SCUSTOM.
    SCUSTOM-ID        = '12400177'.
    SCUSTOM-NAME      = 'Robinson'.
    SCUSTOM-POSTCODE  = '69542'.
    SCUSTOM-CITY      = 'Heidelberg'.
    SCUSTOM-CUSTTYPE  = 'P'.
    SCUSTOM-DISCOUNT  = '003'.
    SCUSTOM-TELEPHONE = '06201/44889'.
    MODIFY SCUSTOM.
    Addition 1
    ... FROM wa
    Effect
    The values for the line to be inserted or updated are not taken from the table work area dbtab, but from the explicitly specified work area wa. When doing this, the data is read from left to right according to the structure of the table work area dbtab (see TABLES). Since the structure of wa is not taken into account, the work area wa must be at least as wide (see DATA) as the table work area dbtab and the alignment of the work area wa must correspond to the alignment of the table work area. Otherwise, a runtime error occurs.
    Note
    If a work area is not explicitly specified, the values for the line to be inserted or updated are also taken from the table work area dbtab if the statement is in a FORM or FUNCTION where the table work area is stored in a formal parameter or local variable of the same name.
    Addition 2
    ... CLIENT SPECIFIED
    Effect
    Switches off automatic client handling. This allows you to edit data across all clients even when dealing with client-specific tables. The client field is treated like a normal table field that can be programmed to accept values in the table work area dbtab or *dbtab where the line to be edited occurs.
    The addition CLIENT SPECIFIED must be specified immediately after the name of the database table.
    Variant 2
    MODIFY dbtab FROM TABLE itab.or
    MODIFY (dbtabname) FROM TABLE itab.
    Addition:
    ... CLIENT SPECIFIED
    Effect
    Mass modify: Inserts new lines or updates existing lines of a database table. The primary keys for identifying the lines to be inserted or updated and the relevant values are taken from the internal table itab. The lines of the internal table itab must satisfy the same conditions as the work area wa in addition 1 to variant 1.
    Note
    If the internal table itab is empty, SY-SUBRC and SY-DBCNT are set to 0.
    Addition
    ... CLIENT SPECIFIED
    Effect
    As for variant 1.
    Variant 3
    MODIFY dbtab VERSION vers. or
    MODIFY *dbtab VERSION vers.
    See Cannot Use the VERSION Addition.
    Note
    This variant is obsolete.
    Effect
    Inserts a new line or updates an existing line in a database table, the name of which is taken from the field vers at runtime. If no line exists with the specified primary key, an INSERT is executed. Otherwise, an UPDATE is performed. The database table must be defined in the ABAP/4 Dictionary and its name must conform to the naming conventions for R/2 ATAB tables. These stipulate that the name must begin with 'T' and may contain up to four further characters. The field vers must contain the table name without the leading 'T'. Only lines in the current client are inserted or updated. The line to be inserted is taken from the statically specified table work area dbtab or *dbtab.
    SY-SUBRC is set to 0 if the line is successfully inserted or updated. SY-SUBRC <> 0 is not possible since any other result causes a runtime error.
    Hope this helps.
    ashish

  • How to get the complete definition of a table using SQL?

    How to get the complete definition code of a table using SQL?

    Something like this ?
    SQL> set long 10000
    SQL> set pages 200
    SQL> select dbms_metadata.get_ddl('TABLE','EMP') from dual;
    DBMS_METADATA.GET_DDL('TABLE','EMP')
      CREATE TABLE "SCOTT"."EMP"
       (    "EMPNO" NUMBER(4,0),
            "ENAME" VARCHAR2(10),
            "JOB" VARCHAR2(9),
            "MGR" NUMBER(4,0),
            "HIREDATE" DATE,
            "SAL" NUMBER(7,2),
            "COMM" NUMBER(7,2),
            "DEPTNO" NUMBER(2,0),
             CONSTRAINT "PK_EMP" PRIMARY KEY ("EMPNO")
      USING INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS
      STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
      PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
      TABLESPACE "USERS"  ENABLE,
             CONSTRAINT "FK_DEPTNO" FOREIGN KEY ("DEPTNO")
              REFERENCES "SCOTT"."DEPT" ("DEPTNO") ENABLE
       ) PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS LOGGING
      STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
      PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
      TABLESPACE "USERS"
    SQL>Amardeep Sidhu

  • How to get custom field name and value in data table using csom

    i am using using this code but iam not getting FieldValues property..
     internal void ReadProjectCustomFields(string strProjectName)
                string url = "https://techwhizepm.sharepoint.com/sites/rnd/";
                using (ProjectContext projContext = new ProjectContext(url))
                    SecureString passWord = new SecureString();
                    foreach (char c in "Pass@word123".ToCharArray()) passWord.AppendChar(c);
                    projContext.Credentials = new SharePointOnlineCredentials("[email protected]", passWord);
                    projContext.Load(projContext.Projects, o => o.Where(i => i.Name == strProjectName));
                    projContext.ExecuteQuery();
                    foreach (PublishedProject _t in projContext.Projects)
                        DraftProject dftproj = _t.Draft;
                        //CustomFieldCollection custs = dftproj.CustomFields;
                        CustomFieldCollection custfs = dftproj.CustomFields;
                        projContext.Load(dftproj);
                        projContext.Load(custfs);
                        projContext.ExecuteQuery();
                        ddlcfields.Items.Clear();
                        if (!custfs.Count().Equals(0))
                            ddlcfields.DataSource = custfs.AsEnumerable().Select(o=>o.Name);
                            ddlcfields.DataBind();
                        DataTable dt = new DataTable();
                        dt.Columns.Add("Name", typeof(string));
                        dt.Columns.Add("InternalName", typeof(string));
                        dt.Columns.Add("FieldType", typeof(string));
                        //dt.Columns.Add("FinishDate", typeof(string));
                        DataRow dr = null;
                        foreach (CustomField _cust in dftproj.CustomFields)
                            dr = dt.NewRow();
                            dr["Name"] = _cust.Name;
                            string intername = _cust.InternalName;
                            dr["FieldValue"] = dftproj[intername].ToString();
                            //dr["FinishDate"] = _task.Finish;
                            dt.Rows.Add(dr);
                        GridView1.DataSource = dt;
                        GridView1.DataBind();

    I am looking through the API calls in FDM Workbench, but cannot see the table (tPOVPartitions) you mentioned listed. Is this the correct name? And do I just use the function listed in the object browser to run the query?
    Furthermore (going back to my initial thoughts of using strFile), it appears that although the variable contains the .Dat filename and path, the actual file is non-existent when "BefExportToDat" is executed:
    Error:
    Error: Export failed.
    Detail: File not found.
    This would make sense, but it does make the variable "strFile" a little pointless since one cannot make use of the file in this particular event script. Do you please have any thoughts on this?

  • How to get column default value define on table?

    Hi,
    I am trying to get a table column default value with no success. I am using the Oracle Data Provider for .NET 10g Release 2 (10.2.0.2)
    1). OracleConnection.GetSchema( "Columns", New System.String() {"<Owner>", "<Table_Name>"} returns everything BUT default value.
    2). I tried querying oracle directly (sample below) but the default value comes back blank even though the column has one defined.
    Dim oracleConnection As Oracle.DataAccess.Client.OracleConnection = factory.CreateConnection
    Dim oracleCommand As New Oracle.DataAccess.Client.OracleCommand( _
    "SELECT data_default FROM DBA_TAB_COLUMNS WHERE OWNER = 'TEST_SCHEMA' AND UPPER( TABLE_NAME ) = 'TEST' AND UPPER(COLUMN_NAM) = 'TESTCOL'")
    oracleConnection.Open()
    oracleCommand.Connection = oracleConnection
    Dim oracleReader As Oracle.DataAccess.Client.OracleDataReader = oracleCommand.ExecuteReader
    oracleReader.GetValue(0) 'This will return blank rather than default value for the column.
    oracleReader.Read()
    oracleReader.Close()
    oracleConnection.Close()
    Any help would be appreciated.
    Thanks,
    Rob Panosh
    Advanced Software Designs

    Hi Rob,
    I just ran up a quick test and I can't duplicate the behavior you describe.
    I created a simple table as "scott":
    SQL> create table def_test(c varchar2(32) default 'hello, world');
    Table created.In my simple test I used the following C# code:
    NOTE: There is an error in this code if using ODP.NET (see my post below for details on this)
    using System;
    using System.Data;
    using System.Data.OracleClient;
    class Program
      static void Main(string[] args)
        string constr = "user id=scott;" +
                        "password=tiger;" +
                        "data source=orademo;" +
                        "pooling=false;" +
                        "enlist=false";
        OracleConnection con = new OracleConnection(constr);
        con.Open();
        OracleCommand cmd = con.CreateCommand();
        cmd.CommandText = "select   data_default " +
                          "from     all_tab_columns " +
                          "where    owner='SCOTT' " +
                          "and      table_name='DEF_TEST' " +
                          "and      column_name='C'";
        OracleDataReader dr = cmd.ExecuteReader();
        dr.Read();
        string defaultValue = (string) dr.GetValue(0);
        Console.WriteLine("Default value is: {0}", defaultValue);
        dr.Dispose();
        cmd.Dispose();
        con.Dispose();
    }Since the GetValue method returns an "object" I cast the value to a string and got the correct result.
    However, I don't have a 10.2 ODP.NET environment right now so I was using 11.1 for this.
    In your real code I suspect that you assign "oracleReader.GetValue(0)" to something - when you say "blank" do you mean zero length or a space or something else?
    Regards,
    Mark
    Edited by: Mark Williams on Jul 31, 2009 10:02 AM

Maybe you are looking for

  • Limitation on mails in Iphone 5 with IOS7

    Hi, Is there any way where i can limit the mails on my Iphone 5 updated to ios 7.0.3. The earlier ios 6 had an option to limit it but i am unable to find the option for ios 7. I have 7 mail ids and and it is consuming more space on my device. If i ca

  • Inserting data in a table and checking

    create or replace procedure testpara1( p_IN in VARCHAR2,p_result out varchar2) Is CURSOR cur_key IS       SELECT * FROM object_keywords; TYPE objkey_tab_type IS TABLE OF OBJECT_KEYWORDS%ROWTYPE; v_keywords  objkey_tab_type; v_keepwords varchar2(100);

  • Problems/Errors with MS SQL7-Migration to Oracle8i

    I have a problem with the migration from MS SQL7 to Oracle 8i. I start the Migration Workbench (create Oracle-Modell in a Oracle-Database), migration tables - ok, indexes - ok, first views - ok then errors. I get the error "ORA-03114" ("Not connected

  • Looking for Free Site Search

    I'm looking for a Site Search script (hopefully free) for ** windows servers ** that works like ones I've used in UNIX. One of the great features the UNIX program has is the ability to define or restrict the files and folders to be gone through in th

  • HT4528 deleting unwanted apps

    I have an iphone 4.  How do I delete messages I no longer want?