Oracle Projects - data upload from excell

Dear Experts,
Currently we are in the process of  implementing oracle R12.1.3  .   Consultants  are in the stage of BRD requirement analysis.
Projects  billing, costing, management and service contract.
Here  as per our business requirement, we need to upload the excel - items  which are having around  200+ items for every projects.(manual entry is not possible )
Now , we  the client  and the consultants  are do not know  how to do this.
Can you please explore the possibilities of  excel sheet upload to projects
Required result is:
Upload data in projects costing, then data move  to INV and all other rest flows.
Thanks

If an open interface/API is not available, you might want to take a look at DataLoad (dataload.com); if interface/API is available and you want to use Excel, a custom Web ADI integrator can be created.

Similar Messages

  • Data upload from excel into SAP

    Hi Gurus
    Could anyone please guide me how to upload excel data into SAP?
    I need to update existing Gross weight and Net weight data. Got new data in excel format.So need to upload excel file straight into SAP and update the data.
    Step by step procedure will be much appreciated.
    Rgds
    Utpal

    try with bdc .....
    below coding is move the data from excel to internal table ....
    TYPES: BEGIN OF s_ovro,
              VKORG LIKE V_TVSFK-VKORG,
              VTWEG LIKE V_TVSFK-VTWEG,
              SPART LIKE V_TVSFK-SPART,
              STGKU LIKE V_TVSFK-STGKU,
              STGAK LIKE V_TVSFK-STGAK,
              STAFO LIKE V_TVSFK-STAFO,
           END OF s_ovro.
    DATA: I_OVRO TYPE TABLE OF s_ovro,
          w_ovro type s_ovro.
    data : request(15) type c,
            i type c.
    DATA : IT_EXCEL TYPE STANDARD TABLE OF ALSMEX_TABLINE WITH HEADER LINE.
    FIELD-SYMBOLS: <FS1> TYPE ANY.
    include bdcrecx1.
    SELECTION-SCREEN BEGIN OF BLOCK DATA WITH FRAME.
    PARAMETERS: P_FILE TYPE  RLGRAP-FILENAME DEFAULT 'C:\Documents and Settings\itfactory\Desktop\sd1.xls' OBLIGATORY.
    SELECTION-SCREEN END OF BLOCK DATA.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_FILE.
      CALL FUNCTION 'F4_FILENAME'
        EXPORTING
          PROGRAM_NAME  = SYST-CPROG
          DYNPRO_NUMBER = SYST-DYNNR
          FIELD_NAME    = 'P_FILE'
        IMPORTING
          FILE_NAME     = P_FILE.
    start-of-selection.
    CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
        EXPORTING
          FILENAME                = P_FILE
          I_BEGIN_COL             = 1
          I_BEGIN_ROW             = 1
          I_END_COL               = 24
          I_END_ROW               = 60000
        TABLES
          INTERN                  = IT_EXCEL
        EXCEPTIONS
          INCONSISTENT_PARAMETERS = 1
          UPLOAD_OLE              = 2
          OTHERS                  = 3.
      LOOP AT IT_EXCEL.
        ASSIGN COMPONENT IT_EXCEL-COL OF STRUCTURE
        W_ovro TO <FS1>.
        <FS1> = IT_EXCEL-VALUE.
        AT END OF ROW.
         MOVE-CORRESPONDING: Wib TO Iib.
          APPEND w_ovro to I_ovro.
          CLEAR W_ovro.
        ENDAT.
      ENDLOOP.
    through bdc program update the data from internal table to bdc...

  • GLPLUP - big uploads from Excel

    Transaction code GLPLUP (program G_FLEX_UPL) is used for budget data upload in SAP ECC6. There are need for about 250000 budget data rows to be uploaded into SAP. With GLPLUP can be uploaded about 1400 rows per one time, so with 250000 rows would mean the uploads for quite many times and this seems not so sensible.
    Is there any (standard) solutions for big budget data uploads from Excel into SAP?

    Thanks for the tips!
    We created transaction ZGLPLUP and Excel file is to be uploaded into SAP. Budget upload is processed in batch input session. In that way it could be processed also big amounts of data and output logs could also be created.

  • Date conversion from Excel to the SAP format

    Hi,
    I have created a BDC program which uploads daat from Excel sheet.
    There is a date field also, the format of which can be any as per the end user (it will be one of those allowed by SAP).
    However, the file will be used for execution by another user who may have a date setting which is different than that from the one in Excel.
    Eg. End User's date format: DD.MM.YYYY, SAP User's date format: MM/DD/YYYY
    So, how do I convert the date format from excel to the format which will be accepted by the transaction during the recording?
    Regards,
    Dave

    Hi Dave,
    I have faced the same issue while uploading the date to the bdc.
    if ur date format is DD.MM.YYYY in the excel file, first of all you need to change this to dats format ie YYYYMMDD ie character8 format and pass to the bdc, it will automatically convert to sap format
    ie you need to convert splitting at .
    data lv_date type char10,
            lv_dd type char02,
            lv_mm type char02,
           lv_yyyy type char04,
    v_date type char08.
    lv_date = '30.12.2011'.
    split lv_date at '.' into lv_dd lv_mm lv_yyyy.
    if strlen(lv_dd) lt 2.
       concatenate '0' lv_dd into lv_dd.
    endif.
    if strlen(lv_mm) lt 2.
       concatenate '0' lv_mm into lv_mm.
    endif.
    concatenate lv_yyyy lv_mm lv_dd into v_date.
    "Please use the variable V_DATE to populate to ur bdc"
    Edited by: Rahul Babukuttan on Aug 11, 2011 5:35 PM

  • How to schedule Job for data uploading from source to BI

    Hi to all,
    How to schedule Job for data uploading from source to BI,
    Why we required and how we do it.
    As I am fresher in BI, I need to know from bottom.
    Regards
    Pavneet Rana

    Hi.
    You can create [process chain |http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/502b2998-1017-2d10-1c8a-a57a35d52bc8?quicklink=index&overridelayout=true]for data loading pocess and schedule start process to any time/date etc ...
    Regadrs.

  • Can I recover my data information from excel file?

    For any reason I already lost (clear all) my data information, have any option where import the data information from excel file to view responses sheet? or , how, can I recover my data information?
    Antonio

    If you had saved your Excel file, then you may revert the Excel file to the last saved version. Follow below steps to do this:
    On the File tab, click Open.
    Double-click the name of the file that you have open in Excel.
    Click Yes to reopen the Excel file.
    If you had not saved Excel file, then follow below steps to recover your file.
    Click the File tab.
    Click Recent.
    Click Recover Unsaved Workbooks.

  • Error Message in Data IMport from Excel

    Hi All
    Please can you help - I am trying to import some BP data using the option in the menu Administration - Data Import/Export - Data Import from Excel.
    I have created my import file as a text file and provided the relevant mappings. Having located my text file, I then get the following error message:
    Row Number 1:Internal error (-2007) occurred.
    Has anyone got any ideas as to what this means I've done wrong?
    Thanks

    Dear, 
    Kindly refer to note 1296487 below:
    Symptom
    In attempt to import a Business Partner from an Excel file to SAP
    Business One, the following error messages are displayed and the
    Business Partner is not imported:
        o  When there are no House Banks in the company, the following error
           messages are displayed:
        Row Number 1: Internal error 'House Bank Accounts' occurred,
    and,0 Records imported successfully.
         o  When there are no Payment Methods in the company, the following
            error messages are displayed:
         Internal error 'Payment Methods for Payment Wizard' (OPYM)
    (-2007) occurred, and, 0 Records imported successfully.
         o  When Payment Methods and House Bank are defined in the company,
            the following error messages are displayed:
         Row Number 1: Internal error (-2007) occurred, and,
         0 Records imported successfully.
    Other terms
    DB, export, BP
    Reason and Prerequisites
    Application error
    Solution
    SAP intends to provide patches in order to solve described problem.
    The section Reference to related Notes below will list the specific
    Patches when available.
    The corresponding Info file of Patches on SAP Service Marketplace will
    show the correction / SAP Note number also.
    Be aware that these references can only be set at Patch release date.
    SAP will deliver Patches only for selected Releases at its own
    discretion, based on the business impact and the complexity of the
    implementation.
    If it is your case, We would like to inform you that we plan to fix the problem you raised,
    in patch 05 for SAP Business One 2007 A FP01 / SP01 Release.
    For SAP Business One Patch Delivery Schedule please look at:
    http://service.sap.com/smb/sbo/patches
    Best regards,
    Apple

  • Oracle table data to MS EXcel

    Is there is anyway i could transfers an oracle table data to MS EXcel, pls advice

    You can also use oracle's com feaatures to achieve this . you can find the com directory in oracle_home/ admin/ora91/com .go through the readme file there and you soon relize , how easy is this ?
    hare krishna
    Alok

  • Data upload from R3 to BPC using filters

    We are facing a performance issue on the uploading data flow from R3 to BPC. Two steps have been set up.
    Step1: R/3 --> ODS --> BW CUBE (No filters and full mode)
    Step2: BW  CUBE --> BPC CUBE (Standard BW upload package)
    The first one (from R3 to a BW Cube) has no filters, so it loads every data and it takes too much time. However, the second one (from the Cube to BPC)  has filtering options, so we can only load the data we need to (we usually use entity and time filters).
    Both are executed from the BPC DataManager.
    Any advice to improve the performance of the first step? Could we join the step 1 and step 2 and get the filters from the standard BW upload process using a custom process chain?
    Does anybody have any experience using filters to reduce the amount of records on the data uploading from R/3 to BPC?
    BPC Version 7.50.15

    Hi,
    for example in BI data is stored as below
    GroupAcc - Date - Balance
    100000 - 12.12.10 - 400
    **I'm not quite sure how you are getting the above data from infocube.Are you directly loading data from PSA to infocube with out loading data into DSO -0FIGL_O10(General ledger(New):Transaction figures) ?
    To get required format of following data, no need to do any thing while laoding the data into BPC. Your BI infocube should maitain the data in below format.
    GroupAcc - Date - Balance
    100000 - 12.12.10 - 100 - (LC)
    100000 - 12.12.10 - 100 - (TC)
    100000 - 12.12.10 - 200 - (GC)
    To acheive above format of data in the infocube please follow standard way of data flow given by SAP in BI Contect(http://help.sap.com/saphelp_nw70ehp1/helpdata/en/e6/f16940c3c7bf49e10000000a1550b0/frameset.htm).
    Flow should be
    R/3 --> PSA --> DSO -->Infocube.
    In this flow its important to remember about infoobect 0CURKEY_TC in DSO.
    This is always the currency key of the transaction currency; it is also filled for records with a different currency type. Without this key field, postings with different transaction currencies would be overwritten after summarization and thereby be lost.
    (http://help.sap.com/saphelp_nw70ehp1/helpdata/en/a8/e26840b151181ce10000000a1550b0/content.htm)
    Once you follow the standard flow, your infocube contains the requried format (LC,TC and GC )of data to load it into BPC application.
    hope it helps...
    regards,
    Raju

  • Mass Master data Upload from MS Excel and JDE into SAP ( ECC 6.0)

    Hi
    We are deciding the best method of uploading 2 million fixed assets Master data from Excel and JDE
    We are following Batch Input (RAALTD001) and Direct Input methods (RAALTD11)
    I am looking for some other efficient alternative for this upload
    Look forward ot hear form you experts !!
    Thanks
    Milind

    hi
    good
    both works not possible simultaneously.
    If you want to do it in two separate task than you can use the GUI_UPLOAD function module to fulfill your requirement.
    thanks
    mrutyun^

  • Importing Data into MS Project Professional 2013 from Excel workbook, can it be done?

    Hi all, I am trying to get data in from several large work plans done in Excel, into MS Project 2013 Pro. I am familiar with the Import Wizard, but in this case, there is nothing to map from the Excel files it seems. Does that mean that I have to edit the
    Excel files and make sure there is a column called Name to key from? Or do I do something else so I don't have to cut and paste or retype all of this? Well, as always, thx (and thank the heavens u are here). 
    Cheers,
    Jigs
    Jiggy Gaton, Trainer and Media Consultant for Nepal and S. Asia

    Jiggy --
    I think it would help you if you exported a Microsoft Project 2013 file to an Excel workbook so that you can see exactly WHAT data your own Excel workbook should contain.  Please try this:
    Open an existing Microsoft Project 2013 file.
    Click File > Export > Save Project as File > Microsoft Excel Workbook and then click the Save As button on the Export page.
    In the Save As dialog, navigate to the folder where you want to save the Excel workbook file, and then click the Save button.
    In the Export Wizard dialog, click the Next button.
    On the Data page of the Export Wizard, select the Project Excel Template option, and then click the Finish button.
    If you see a warning message about a missing filter, simply click the OK button, as this is a bug that will not affect the exported data.
    Now, open the resulting workbook in Microsoft Excel.  Pay special attention to the data shown on the Task_Table worksheet.  Notice in row 1 how every column has a heading that describes the data.  Notice that the column containing the Task
    Name information is not called Task Name; it is simply called Name.
    What you will need to do is to configure your own Excel workbook to look like what you see in the Excel workbook that you just exported.  Then try importing your Excel workbook data using the Import Wizard, and let us know if you have follow up questions. 
    Hope this helps.
    Dale A. Howard [MVP]
    Well, I followed this procedure and the results are problematic. First, there is always errors on import, and no matter what's selected, the import works but with problems...
    Multiple import errors of the same type, clicking Yes, No, Cancel produces the same results: 
    Then, unpredictable results on import, most of the time it looks like this: 
    The crossed out text is problematic. I have no idea why it does that, or how to fix. Well, thx for your help!
    Jiggy Gaton, Trainer and Media Consultant for Nepal and S. Asia

  • Regarding upload from excel to alv.

    Hi
    here is my code:
    TABLES
    TABLES: ioheader,        " IOC Communication structure
            ioitem,          " IOC Communication structure
            klah,            " Class and Class type
            ksml,            " Characteristic Keys for Class and Type
            cabn,            " Characteristics
            cabnt,           " Characteristic Descriptions
            vbap,            " SAles details
            sscrfields.
    Includes
    INCLUDE rvreuse_global_data.  " ALV Types etc
    DATA - INTERNAL TABLES AND FIELD LISTS
    Types
    TYPE-POOLS: ibco2.           " Characteristic types
    DATA - CONSTANTS
    CONSTANTS: c_true(1)    TYPE c             VALUE 'X',
               c_false(1)   TYPE c             VALUE ' ',
               c_zioheader  TYPE dd02l-tabname VALUE 'ZIOHEADER',
               c_command    TYPE slis_formname VALUE 'USER_COMMAND',
               c_backhoe(7) TYPE c             VALUE 'BACKHOE',
               c_300(3)     TYPE c             VALUE '300',
               c_no_data(7) TYPE c             VALUE 'No Data',
               c_save(1)    TYPE c             VALUE 'A'.
    Internal Tables
    Main IO Table
    DATA: i_header LIKE zioheader OCCURS 0 WITH HEADER LINE.
    Characteristic Values
    DATA: i_config TYPE ibco2_instance_tab2.
    Characteristics Keys
    DATA: BEGIN OF i_imerk OCCURS 0,
            imerk LIKE ksml-imerk,
          END OF i_imerk.
    ALV Grid Control
    DATA: i_grid TYPE sd_alv.
    Catalogues
    DATA: wa_cat LIKE LINE OF i_grid-fieldcat.
    Structures
    Structure for layout variant
    DATA: s_variant LIKE disvariant.
    DATA : filename TYPE string.
    DATA - WORKING VARIABLES
    DATA - FIELD GROUPS
    *field-groups:
    SELECTION SCREEN
    Variant control
    SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-t02.
    PARAMETERS: p_var LIKE disvariant-variant.
    SELECTION-SCREEN END OF BLOCK b1.
    Printer Control
    SELECTION-SCREEN BEGIN OF BLOCK b3 WITH FRAME TITLE text-t03.
    PARAMETERS: rad1 RADIOBUTTON GROUP rad USER-COMMAND radio,
                rad2 RADIOBUTTON GROUP rad,
                rad3 RADIOBUTTON GROUP rad.
    PARAMETER p_floc(128) DEFAULT '/usr/tmp/testfile.dat'
                             LOWER CASE.
    SELECTION-SCREEN END OF BLOCK b3.
    MAIN PROGRAM *************************
    INITIALIZATION.
      PERFORM initialise.             " Set up program defaults
    move 'Report Only' to rad1.
    move 'Export Sequence List' to s_but2.
    move 'Import Sequence List' to S_but3.
    Selection Screen Options
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_var.
      PERFORM get_variant CHANGING p_var.             " ALV Layout
    DATA :   l_no_of_lines TYPE i,
              la_matnr LIKE s_matnr.
    DESCRIBE TABLE s_matnr LINES l_no_of_lines.
    IF l_no_of_lines > 1.
       MESSAGE e000(z1) WITH 'Enter only one product'.
    ENDIF.
    READ TABLE s_matnr INTO la_matnr WITH KEY sign = 'I'
                               option = 'EQ'.
    IF sy-subrc NE 0.
       MESSAGE e000(z1) WITH 'Enter only one product'.
    ENDIF.
    AT SELECTION-SCREEN.
      DATA :   l_no_of_lines TYPE i,
                la_matnr LIKE s_matnr.
      DESCRIBE TABLE s_matnr LINES l_no_of_lines.
      IF l_no_of_lines > 1.
        MESSAGE e000(z1) WITH 'Enter only one product'.
      ENDIF.
    READ TABLE s_matnr INTO la_matnr WITH KEY sign = 'I'
                                option = 'EQ'.
      IF sy-subrc NE 0.
        MESSAGE e000(z1) WITH 'Enter only one product'.
      ENDIF.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR  p_floc.
    data : pname type syst-repid.
    CALL FUNCTION 'KD_GET_FILENAME_ON_F4'
    EXPORTING
       PROGRAM_NAME        = pname
       DYNPRO_NUMBER       = SYST-DYNNR
       FIELD_NAME          = 'P_FLOC'
      STATIC              = ' '
      MASK                = ' '
      CHANGING
        FILE_NAME           = p_floc
    EXCEPTIONS
      MASK_TOO_LONG       = 1
      OTHERS              = 2
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    START-OF-SELECTION.
      PERFORM set_catalogue.          " Set up basic headings from Itab
      PERFORM get_char_keys.          " Get the characteristic keys
      PERFORM modify_catalogue_key.   " Amend headings for char keys
    IOC Logical Database Event
      GET ioheader.
      PERFORM get_subsequent_data.    " Retrieve additional data
    END-OF-SELECTION.
    PERFORM modify_catalogue_title. " Place correct titles for AVL
    PERFORM alv_display.            " Display in ALV Grid
    if rad1 = 'X' .
      PERFORM modify_catalogue_title. " Place correct titles for AVL
      PERFORM alv_display.            " Display in ALV Grid
    elseif rad2 = 'X' .
    *if p_floc is initial .
    MESSAGE e000(z1) WITH
       ' Enter the file location'.
    *else.
       PERFORM download.               " Export sequence list to excel
    PERFORM modify_catalogue_title. " Place correct titles for AVL
      PERFORM alv_display.            " Display in ALV Grid
    *endif.
    elseif rad3 = 'X' .
    if p_floc is initial .
    MESSAGE e000(z1) WITH
        ' Enter the file location'.
    else .
         PERFORM upload.
    endif.
    endif.
    *AT SELECTION-SCREEN OUTPUT.
    *TOP-OF-PAGE.
    *END-OF-PAGE.
    *AT USER-COMMAND.
    perform PF_STATUS_SET.
    SUBROUTINES *******************************
          FORM get_variant                                              *
          Retrieve ALV display variant                                  *
    -->  X_VAR Variant                                                 *
    FORM get_variant CHANGING x_var.
      PERFORM f4_alv_layout(ppio_entry) USING i_grid-program
                                     CHANGING x_var.
    ENDFORM.
          FORM get_subsequent_data                                      *
          Retrieve additional data and place into I_HEADER Itab         *
    FORM get_subsequent_data.
    Prime extended table
      i_header = ioheader.
      PERFORM get_serial_number. " Get Sales Order Serial No
      PERFORM get_char_values.   " Get Characteristic Values
      PERFORM build_char_entries." Put Char Values into I_HEADER
    Add to extended table
      APPEND i_header.
    ENDFORM.
          FORM get_serial_number                                        *
          Retrieve the serial number                                    *
    FORM get_serial_number.
      SELECT SINGLE zuonr submi
        INTO (i_header-zuonr,i_header-submi)
        FROM vbak
       WHERE vbeln EQ i_header-kdauf_aufk.
    ENDFORM.
          FORM get_char_values                                          *
          Retrieve the characteristic values for the production order   *
    FORM get_char_values.
    Get Ready
      REFRESH i_config.
    Get Object key
      SELECT SINGLE cuobj
      FROM vbap
      INTO vbap-cuobj
      WHERE vbeln EQ i_header-kdauf_aufk
        AND matnr EQ i_header-plnbez.
    Get characteristic config values
      CALL FUNCTION 'CUCB_GET_CONFIGURATION'
           EXPORTING
                instance                     = vbap-cuobj
           IMPORTING
                configuration                = i_config
           EXCEPTIONS
                invalid_input                = 1
                invalid_instance             = 2
                instance_is_a_classification = 3
                OTHERS                       = 4.
    Not found, no config values will be pulled through
      IF sy-subrc <> 0.
      ENDIF.
    ENDFORM.
          FORM build_char_entries                                       *
          For each character value. Find the relevent "slot" in the     *
          table by checking the characteristic key against the catalogue*
          stored key
    FORM build_char_entries.
      DATA: la_config LIKE LINE OF i_config,       " i_config header line
            li_values TYPE ibvalue0 OCCURS 0,      " Charact'ic Values Itab
            la_values LIKE LINE OF li_values,      " li_values header line
            l_atwrt LIKE la_values-atwrt,          " Characteristic Value
            l_atinn LIKE la_values-atinn,          " Characteristic Key
            l_key(20),                             " Working built key
            l_entry(20),                           " FieldName to be updated
            l_len LIKE sy-tabix,                   " Length of string
            l_tabix LIKE sy-tabix.                 " Index position of Itab
      FIELD-SYMBOLS: <f_field>.       " This will be the field to update
    Loop on characteristics
      LOOP AT i_config INTO la_config.
    Extract the characteristic values imbedded table
        MOVE la_config-values TO li_values.
    Loop on the characteristics values
        LOOP AT li_values INTO la_values.
    We now have the charecteristic key la_values-atinn
    and the value in la_values-atwrt. However, there may be
    Multiple values for key la_values-atinn
    So if they are the same append to one long string.
    Is it a new value
          IF la_values-atinn EQ l_atinn.
            CONCATENATE l_atwrt '|' la_values-atwrt INTO l_atwrt.
            CONTINUE.
          ENDIF.
    New Value (and not first pass) so save built values
          IF NOT l_atinn IS INITIAL.
    Find the correct field to place the value in.
    This is done by finding the Itab field description in the AVL display
    field Catalogue called "No Data|nnnnnn" where nnnn is the
    characteristic Key
    Build the key
            CONCATENATE c_no_data '|' l_atinn INTO l_key.
    Loop till we find it. This gives us the field name
            LOOP AT i_grid-fieldcat INTO wa_cat WHERE seltext_l = l_key.
    Set up the field name to be amended
              CONCATENATE wa_cat-tabname '-' wa_cat-fieldname INTO l_entry.
              ASSIGN (l_entry) TO <f_field>.
    Update field with the Char value
              MOVE l_atwrt TO <f_field>.
    No need to continue this loop
              EXIT.
            ENDLOOP.
          ENDIF.
    Prime for next value
          l_atinn = la_values-atinn.
          l_atwrt = la_values-atwrt.
        ENDLOOP.
      ENDLOOP.
    ENDFORM.
          FORM alv_display                                              *
          Display data in ALV grid                                      *
    FORM alv_display.
    Set up Variant
      i_grid-variant-variant = p_var.     " Variant
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
      EXPORTING
      I_INTERFACE_CHECK              = ' '
      I_BYPASSING_BUFFER             =
      I_BUFFER_ACTIVE                = ' '
        i_callback_program             = i_grid-program
       I_CALLBACK_PF_STATUS_SET       =  i_grid-pf_status_set
        i_callback_user_command        = i_grid-user_command
      i_structure_name               = i_grid-structure
      is_layout                      = i_grid-layout
        it_fieldcat                    = i_grid-fieldcat
      IT_EXCLUDING                   = i_grid-excluding
      IT_SPECIAL_GROUPS              = i_grid-special_groups
      IT_SORT                        = i_grid-sort
      IT_FILTER                      = i_grid-filter
      IS_SEL_HIDE                    = i_grid-sel_hide
      I_DEFAULT                      = i_grid-default
        i_save                         = I_grid-save
        is_variant                     = i_grid-variant
      IT_EVENTS                      = i_grid-events
      IT_EVENT_EXIT                  = i_grid-event_exit
      IS_PRINT                       = i_grid-print
      IS_REPREP_ID                   =
      I_SCREEN_START_COLUMN          = i_grid-start_column
      I_SCREEN_START_LINE            = i_grid-start_line
      I_SCREEN_END_COLUMN            = i_grid-end_column
      I_SCREEN_END_LINE              = i_grid-end_line
    IMPORTING
      E_EXIT_CAUSED_BY_CALLER        = i_grid-exit
      ES_EXIT_CAUSED_BY_USER         = i_grid-user_exit
        TABLES
         t_outtab                      = i_header
       EXCEPTIONS
        program_error                  = 1
        OTHERS                         = 2.
    ALV Failed.
      IF sy-subrc <> 0.
        WRITE: / 'Failed with',sy-subrc.
      ENDIF.
    ENDFORM.
          FORM initialise                                               *
          Set up basic report details                                   *
    FORM initialise.
    ALV controls
      i_grid-program = sy-repid.          " Program Name
      i_grid-user_command = c_command.    " ALV user FORM
      i_grid-save = c_save.               " Save Options
    ALV Variant Details for saved report layouts
      i_grid-variant-report = i_grid-program.
      i_grid-variant-username = sy-uname.
    ENDFORM.
          FORM user_command                                             *
          Routine called by ALV                                         *
    -->  X_UCOMM    Function selected                                  *
    -->  X_SELFIELD Selection field Itab                               *
    FORM user_command USING x_ucomm    LIKE sy-ucomm
                            x_selfield TYPE slis_selfield.
      DATA: l_answer(1).        " Answer returned from popup box
    Only allow drill down on Order number
      CHECK x_selfield-fieldname = 'AUFNR'.
    Get option for display or modify
      CALL FUNCTION 'POPUP_TO_DECIDE'
           EXPORTING
                textline1    = 'Please Choose'
                text_option1 = 'Display'
                text_option2 = 'Modify'
                titel        = 'Production Order'
           IMPORTING
                answer       = l_answer.
    Did they cancel
      CHECK l_answer NE 'A'.
    Set up parameters.
      SET PARAMETER ID 'ANR' FIELD x_selfield-value.
    Display
      IF l_answer = '1'.
        CALL TRANSACTION 'CO03' AND SKIP FIRST SCREEN.
    Modify
      ELSEIF l_answer = '2'.
        CALL TRANSACTION 'CO02' AND SKIP FIRST SCREEN.
      ENDIF.
    *IF rad2 = 'X'.
    If sy-ucomm ='%PC'.
    IF sy-subrc <> 0.
        WRITE: / 'Failed with',sy-subrc.
      else.
      CALL FUNCTION 'POPUP_TO_INFORM'
        EXPORTING
          TITEL         = 'File Transfer Status'
          TXT1          = 'File transfered to location:'
          TXT2          = filename
        TXT3          = ' '
        TXT4          = ' '
        ENDIF.
    endif.
    ENDFORM.
          FORM set_catalogue                                            *
          Retrieve the title and field information from the             *
          Data Dictionary. This will then be amended to the correct     *
          Characteristic titles during the end-of-selection event       *
    FORM set_catalogue.
      CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'
           EXPORTING
                i_program_name         = i_grid-program
                i_internal_tabname     = 'I_HEADER'
                i_structure_name       = c_zioheader
                i_client_never_display = 'X'
           CHANGING
                ct_fieldcat            = i_grid-fieldcat.
    ENDFORM.
          FORM get_char_keys                                            *
          Retrieve the list of characteristic keys                      *
          template of BACKHOE class 300                                 *
    FORM get_char_keys.
      DATA : la_inob TYPE inob.
      SELECT SINGLE * FROM inob INTO la_inob
                     WHERE objek = s_matnr-low.
      IF sy-subrc NE 0.
        MESSAGE e000(z1) WITH
        ' Could not get INOB table for ' s_matnr-low.
      ENDIF.
    Get Major Object key
      SELECT SINGLE clint
        FROM klah
        INTO klah-clint
       WHERE klart = la_inob-klart
         AND class = s_matnr-low.
      IF sy-subrc NE 0.
        MESSAGE e001(z296) WITH c_backhoe c_300.
      ENDIF.
    Use Major key to retrieve Characteristics keys
    This is the template for the headings
      SELECT imerk
        FROM ksml
        INTO TABLE i_imerk
       WHERE clint EQ klah-clint    " Objct Key
         AND lkenz EQ space         " Delete Indicator
         AND datuv LE sy-datum.     " Validity to
      IF sy-subrc NE 0.
        MESSAGE e002(z296) WITH klah-clint.
      ENDIF.
    ENDFORM.
          FORM modify_catalogue_key                                     *
          Change the default "No Data" titles with the characteristic   *
          key values in the form "No Data|nnnnnnn" where nnnnnn is      *
          the characteristic key. This is used as a method of allocating*
          characteristic values to the I_HEADER Itab positions          *
          CHAR_001 to CHAR_100                                          *
    FORM modify_catalogue_key.
      DATA: l_index LIKE sy-tabix,              " Table Index for Read
            l_tabix LIKE sy-tabix,              " Table Index Position
            l_seltext_l LIKE dd03p-scrtext_l.   " Heading Text
    Get into Key Sequence
      SORT i_imerk.
    Loop on catalogue for dummy titles
      LOOP AT i_grid-fieldcat INTO wa_cat WHERE seltext_l(7) = c_no_data.
        l_tabix = sy-tabix.
    Get the next characteristic
        l_index = l_index + 1.
        READ TABLE i_imerk INDEX l_index.
    No Characteristic, No display
        IF sy-subrc NE 0.
          wa_cat-no_out = c_true.
          wa_cat-tech = c_true.
          MODIFY i_grid-fieldcat FROM wa_cat INDEX l_tabix.
          CONTINUE.
        ENDIF.
    Place the char key against the "No Data" title
    so that later we know what values to place against the keys
    the title will become "No Data:nnnnnnnnnn" (nnn = Key)
        CONCATENATE c_no_data '|' i_imerk-imerk INTO wa_cat-seltext_l.
        MODIFY i_grid-fieldcat FROM wa_cat INDEX l_tabix.
      ENDLOOP.
    ENDFORM.
          FORM modify_catalogue_title                                   *
          At this stage the catalogue titles for the characteristics    *
          are in the form "No Data|nnnnn" Where nnnn is the             *
          characteristic key. Using the Key, replace this text with     *
          the real characteristic title
    FORM modify_catalogue_title.
      DATA: l_key(20),                 " Characteristic Key in Alpha form
            l_len LIKE sy-tabix.       " Length of string
    Loop on the characteristic keys
      LOOP AT i_imerk.
    Get the real title
        SELECT SINGLE atbez
          FROM cabnt
          INTO cabnt-atbez
         WHERE atinn EQ i_imerk-imerk.
    Not found, leave alone
        CHECK sy-subrc EQ 0.
    Place key into char form for comparison in loop
        l_key = i_imerk-imerk.
    Now loop on the catalogue to get the key
        LOOP AT i_grid-fieldcat INTO wa_cat WHERE seltext_l+8 = l_key.
    Place the title into the catalogue
          wa_cat-seltext_l = cabnt-atbez.
          wa_cat-seltext_m = cabnt-atbez.
          wa_cat-seltext_s = cabnt-atbez.
          wa_cat-reptext_ddic = cabnt-atbez.
    And update
          MODIFY i_grid-fieldcat FROM wa_cat.
        ENDLOOP.
      ENDLOOP.
    IF rad2 = 'X'.
    LOOP AT i_grid-fieldcat INTO wa_cat.
    *IF wa_cat-fieldname = 'AUFNR'.
    *wa_cat-col_pos = '10'.
    *endif.
    case wa_cat-fieldname.
    when 'AUFNR'.
    wa_cat-fix_column = 'X'.
    when 'CY_SEQNR'.
    wa_cat-fix_column = 'X'.
    when 'ZOUNR'.
    wa_cat-fix_column = 'X'.
    when 'GLTRP'.
    wa_cat-fix_column = 'X'.
    when 'SUBMI'.
    wa_cat-fix_column = 'X'.
    endcase.
    modify  i_grid-fieldcat FROM wa_cat.
    endloop.
    endif.
    ENDFORM.
    *SELECT z099seqno z099heading
          INTO table i_header
          FROM z099 join z100 ON
          z099seqno = z100seqno WHERE
    z100~product = s_matnr.
    *&      Form  download
          Download file to excel
    *FORM download.
    *filename = p_floc .
    *CALL FUNCTION 'GUI_DOWNLOAD'
    EXPORTING
      BIN_FILESIZE                  =
       FILENAME                      = filename
       FILETYPE                      = 'ASC'
       APPEND                        = 'X'
      WRITE_FIELD_SEPARATOR         = ','
      HEADER                        = 'l_seltext_l'
      TRUNC_TRAILING_BLANKS         = ' '
      WRITE_LF                      = 'X'
      COL_SELECT                    = ' '
      COL_SELECT_MASK               = ' '
      DAT_MODE                      = ' '
    IMPORTING
      FILELENGTH                    =
    TABLES
       DATA_TAB                      = i_header
    EXCEPTIONS
      FILE_WRITE_ERROR              = 1
      NO_BATCH                      = 2
      GUI_REFUSE_FILETRANSFER       = 3
      INVALID_TYPE                  = 4
      NO_AUTHORITY                  = 5
      UNKNOWN_ERROR                 = 6
      HEADER_NOT_ALLOWED            = 7
      SEPARATOR_NOT_ALLOWED         = 8
      FILESIZE_NOT_ALLOWED          = 9
      HEADER_TOO_LONG               = 10
      DP_ERROR_CREATE               = 11
      DP_ERROR_SEND                 = 12
      DP_ERROR_WRITE                = 13
      UNKNOWN_DP_ERROR              = 14
      ACCESS_DENIED                 = 15
      DP_OUT_OF_MEMORY              = 16
      DISK_FULL                     = 17
      DP_TIMEOUT                    = 18
      FILE_NOT_FOUND                = 19
      DATAPROVIDER_EXCEPTION        = 20
      CONTROL_FLUSH_ERROR           = 21
      OTHERS                        = 22
    IF sy-subrc <> 0.
       WRITE: / 'Failed with',sy-subrc.
    else.
    CALL FUNCTION 'POPUP_TO_INFORM'
       EXPORTING
         TITEL         = 'File Transfer Status'
         TXT1          = 'File transfered to location:'
         TXT2          = filename
        TXT3          = ' '
        TXT4          = ' '
       ENDIF.
    *ENDFORM.                    " download
    *&      Form  upload
          text
    -->  p1        text
    <--  p2        text
    FORM upload.
    *DATA : i_upload TYPE STANDARD TABLE OF alsmex_tabline.
    **data : i_upload like zioheader occurs 0 with header line.
    data file like RLGRAP-FILENAME.
    file = p_floc .
    DATA: BEGIN OF i_upload OCCURS 0.
            INCLUDE STRUCTURE  alsmex_tabline.
    DATA: END OF i_upload.
    DATA: BEGIN OF i_upload1 OCCURS 0.
            INCLUDE STRUCTURE  alsmex_tabline.
    DATA: END OF i_upload1.
    DATA: BEGIN OF t_col OCCURS 0,
           col LIKE alsmex_tabline-col,
           size TYPE i.
    DATA: END OF t_col.
    DATA: zwlen TYPE i,
          zwlines TYPE i.
    DATA: BEGIN OF fieldnames OCCURS 3,
            title(60),
            table(6),
            field(10),
            kz(1),
          END OF fieldnames.
    DATA: tind(4) TYPE n.
    FIELD-SYMBOLS: <fs1>.
    DATA: zwfeld(19).
    CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
      EXPORTING
        FILENAME                      = file
        I_BEGIN_COL                   = '1'
        I_BEGIN_ROW                   = '1'
        I_END_COL                     = '200'
        I_END_ROW                     = '6500'
      TABLES
        INTERN                        = i_upload.
    EXCEPTIONS
      INCONSISTENT_PARAMETERS       = 1
      UPLOAD_OLE                    = 2
      OTHERS                        = 3
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    endif.
    LOOP AT i_upload.
        i_upload1 = i_upload.
        CLEAR i_upload1-row.
        APPEND i_upload1.
      ENDLOOP.
      SORT i_upload1 BY col.
      LOOP AT i_upload1.
        AT NEW col.
          t_col-col = i_upload1-col.
          APPEND t_col.
        ENDAT.
        zwlen = strlen( i_upload1-value ).
        READ TABLE t_col WITH KEY col = i_upload1-col.
        IF sy-subrc EQ 0.
          IF zwlen > t_col-size.
            t_col-size = zwlen.
                             Internal Table, Current Row Index
            MODIFY t_col INDEX sy-tabix.
          ENDIF.
        ENDIF.
      ENDLOOP.
      DESCRIBE TABLE t_col LINES zwlines.
      SORT i_upload BY row col.
    IF kzheader = 'X'.
        LOOP AT i_upload.
          fieldnames-title = i_upload-value.
          APPEND fieldnames.
          AT END OF row.
            EXIT.
          ENDAT.
        ENDLOOP.
    ELSE.
        DO zwlines TIMES.
          WRITE sy-index TO fieldnames-title.
          APPEND fieldnames.
        ENDDO.
    ENDIF.
      SORT i_upload BY row col.
      LOOP AT i_upload.
       IF kzheader = 'X'
        i_upload-row = 1.
          CONTINUE.
       ENDIF.
        tind = i_upload-col.
        CONCATENATE 'DATA_TAB-VALUE_' tind INTO zwfeld.
        ASSIGN (zwfeld) TO <fs1>.
        <fs1> = i_upload-value.
        AT END OF row.
          APPEND i_upload.
          CLEAR i_upload.
        ENDAT.
      ENDLOOP.
    if sy-subrc = 0.
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
      I_INTERFACE_CHECK                 = ' '
      I_BYPASSING_BUFFER                =
      I_BUFFER_ACTIVE                   = ' '
       I_CALLBACK_PROGRAM                = i_grid-program
      I_CALLBACK_PF_STATUS_SET          = ' '
      I_CALLBACK_USER_COMMAND           = ' '
      I_CALLBACK_TOP_OF_PAGE            = ' '
      I_CALLBACK_HTML_TOP_OF_PAGE       = ' '
      I_CALLBACK_HTML_END_OF_LIST       = ' '
      I_STRUCTURE_NAME                  =
      I_BACKGROUND_ID                   = ' '
      I_GRID_TITLE                      =
      I_GRID_SETTINGS                   =
      IS_LAYOUT                         =
       IT_FIELDCAT                       = i_grid-fieldcat
      IT_EXCLUDING                      =
      IT_SPECIAL_GROUPS                 =
      IT_SORT                           =
      IT_FILTER                         =
      IS_SEL_HIDE                       =
      I_DEFAULT                         = 'X'
      I_SAVE                            = i_save
       IS_VARIANT                        = i_grid-variant
      IT_EVENTS                         =
      IT_EVENT_EXIT                     =
      IS_PRINT                          =
      IS_REPREP_ID                      =
      I_SCREEN_START_COLUMN             = 0
      I_SCREEN_START_LINE               = 0
      I_SCREEN_END_COLUMN               = 0
      I_SCREEN_END_LINE                 = 0
      IT_ALV_GRAPHICS                   =
      IT_ADD_FIELDCAT                   =
      IT_HYPERLINK                      =
      I_HTML_HEIGHT_TOP                 =
      I_HTML_HEIGHT_END                 =
    IMPORTING
      E_EXIT_CAUSED_BY_CALLER           =
      ES_EXIT_CAUSED_BY_USER            =
      TABLES
        T_OUTTAB                          = i_upload.
    EXCEPTIONS
      PROGRAM_ERROR                     = 1
      OTHERS                            = 2
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    endif.
    when i execute the program i am getting a short dump
    GETWA_NOT_ASSIGNED
    what might be the problem.
    this is a very urgent question.
    pls suggest me the clear way to over come this problem.

    HI
    use this code for uploading the excel file to internal table....
    data: begin of itab_string occurs 0,
          record type char255,
          end of itab_string.
    data:  L_FILETABLE TYPE FILETABLE,
    L_FILETAB_H TYPE FILETABLE WITH HEADER LINE.
    data: p_file1 type string.
    selection screen .
    PARAMETERS: P_FILE TYPE LOCALFILE.
    initialization.
    at selection-screen on value-request for P_FILE.
    IF THE USER SELECT EXTENTION BUTTON IT WILL OPEN THE LOCAL DIRECTORY FOR SELECTING THE FILE LOCATION.
    CALL METHOD CL_GUI_FRONTEND_SERVICES=>FILE_OPEN_DIALOG
    EXPORTING
       WINDOW_TITLE            =
       DEFAULT_EXTENSION       = 'CSV'
       DEFAULT_FILENAME        = 'C:\Documents and Settings\196093\Desktop\STATUS.csv'
       FILE_FILTER             =
       INITIAL_DIRECTORY        = 'C:\Documents and Settings\196093\Desktop\'
       MULTISELECTION          =
       WITH_ENCODING           =
      CHANGING
        FILE_TABLE              = L_FILETABLE
        RC                      = RC
       USER_ACTION             =
       FILE_ENCODING           =
      EXCEPTIONS
        FILE_OPEN_DIALOG_FAILED = 1
        CNTL_ERROR              = 2
        ERROR_NO_GUI            = 3
        NOT_SUPPORTED_BY_GUI    = 4
        others                  = 5
    IF SY-SUBRC <> 0.
    ELSE.
    LOOP AT l_filetable INTO L_FILETAB_H.
    P_FILE = L_FILETAB_H-FILENAME.
    move p_file to p_file1.
    EXIT.
    ENDLOOP.
    ENDIF.
    passing the selected file name to gui_upload for loading the data
    into internal table
    CALL FUNCTION 'GUI_UPLOAD'
      EXPORTING
        FILENAME                      = p_file1
      FILETYPE                      = 'ASC'
      HAS_FIELD_SEPARATOR           = ' '
      HEADER_LENGTH                 = 0
      READ_BY_LINE                  = 'X'
      DAT_MODE                      = ' '
      CODEPAGE                      = ' '
      IGNORE_CERR                   = ABAP_TRUE
      REPLACEMENT                   = '#'
      CHECK_BOM                     = ' '
      NO_AUTH_CHECK                 = ' '
    IMPORTING
      FILELENGTH                    =
      HEADER                        =
      TABLES
        DATA_TAB                      = itab_string
    EXCEPTIONS
       FILE_OPEN_ERROR               = 1
       FILE_READ_ERROR               = 2
       NO_BATCH                      = 3
       GUI_REFUSE_FILETRANSFER       = 4
       INVALID_TYPE                  = 5
       NO_AUTHORITY                  = 6
       UNKNOWN_ERROR                 = 7
       BAD_DATA_FORMAT               = 8
       HEADER_NOT_ALLOWED            = 9
       SEPARATOR_NOT_ALLOWED         = 10
       HEADER_TOO_LONG               = 11
       UNKNOWN_DP_ERROR              = 12
       ACCESS_DENIED                 = 13
       DP_OUT_OF_MEMORY              = 14
       DISK_FULL                     = 15
       DP_TIMEOUT                    = 16
       OTHERS                        = 17
    IF SY-SUBRC <> 0.
    MESSAGE I000(Z00) WITH 'PLEASE PROVIDE CORRECT FILE NAME'.
    ENDIF.
    reward points to all helpful answers
    kiran.M

  • Problems in uploading from excel sheet to internal table

    hi experts,
    i got one problem regarding uploading data from excel sheet to int.table. I used FM ALSM_EXCEL_TO_INTERNAL_TABLE but in that the value is char of 50. but i need a case where i have to send value more than 50 characters. please suggest me any other FM to overcome this problem.
    advanced thanks
    vijay

    Hi,
    >
    Vijay Krishna Arvapalli wrote:
    > hi tarun,
    >
    > thank you for your reply
    >
    > but when i tried to use FM TEXT_CONVERT_XLS_TO_SAP it is giving error actually that 'Error generating the test frame'.
    >
    > so can you suggest me with some other option where i can upload the field with more than 50 character length.
    >
    > thank you
    > regards
    > vijay
    Yes, when you execute the FM from SE37, then it displays a message.
    Just copy the below code and paste it in a report (SE38) and execute.
    Create a file in C:/ with name test.xls and execute it will display the records even with more than 50 characters of length.
    I have tested and its working.
    I have taken three fields in the excel file empid, name and doj.
    TYPE-POOLS : truxs.
    PARAMETERS : p_file TYPE rlgrap-filename DEFAULT 'C:\TEST.XLS'.
    DATA : BEGIN OF itab OCCURS 0,
             empid(150) TYPE c,
             name(150) TYPE c,
             doj(150) TYPE c,
           END OF itab.
    DATA: it_raw TYPE truxs_t_text_data.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file.
      PERFORM f4_file_process USING p_file.
    AT SELECTION-SCREEN.
      PERFORM validate_file_path USING p_file.
    START-OF-SELECTION.
      PERFORM upload_data.
    END-OF-SELECTION.
      PERFORM display_data.
    *&      Form  F4_FILE_PROCESS
    *       text
    *      -->P_FILE_PATH  text
    FORM f4_file_process USING p_file.
      CALL FUNCTION 'F4_FILENAME'
        EXPORTING
          program_name  = syst-cprog
          dynpro_number = syst-dynnr
          field_name    = 'P_FILE'
        IMPORTING
          file_name     = p_file.
      IF sy-subrc NE 0.
        MESSAGE e000(zsd).
      ENDIF.
    ENDFORM.                    " F4_FILE_PROCESS
    *&      Form  VALIDATE_FILE_PATH
    *       text
    *      -->P_FILE  text
    FORM validate_file_path USING p_file.
      DATA : lv_dir TYPE string,
             lv_file TYPE string,
             lv_result(1) TYPE c.
      DATA : lv_filename TYPE string.
      lv_filename = p_file.
      CALL FUNCTION 'SO_SPLIT_FILE_AND_PATH'
        EXPORTING
          full_name     = p_file
        IMPORTING
          stripped_name = lv_file
          file_path     = lv_dir
        EXCEPTIONS
          x_error       = 1
          OTHERS        = 2.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
      CALL METHOD cl_gui_frontend_services=>directory_exist
        EXPORTING
          directory            = lv_dir
        RECEIVING
          result               = lv_result
        EXCEPTIONS
          cntl_error           = 1
          error_no_gui         = 2
          wrong_parameter      = 3
          not_supported_by_gui = 4
          OTHERS               = 5.
      IF lv_result IS INITIAL.
        MESSAGE 'Invalid Directory' TYPE 'E'.
      ENDIF.
      CLEAR lv_result.
      CALL METHOD cl_gui_frontend_services=>file_exist
        EXPORTING
          file                 = lv_filename
        RECEIVING
          result               = lv_result
        EXCEPTIONS
          cntl_error           = 1
          error_no_gui         = 2
          wrong_parameter      = 3
          not_supported_by_gui = 4
          OTHERS               = 5.
      IF lv_result IS INITIAL.
        MESSAGE 'Invalid File' TYPE 'E'.
      ENDIF.
    ENDFORM.                    " VALIDATE_FILE_PATH
    *&      Form  UPLOAD_DATA
    *       text
    *  -->  p1        text
    *  <--  p2        text
    FORM upload_data .
      CALL FUNCTION 'TEXT_CONVERT_XLS_TO_SAP'
        EXPORTING
          i_field_seperator    = 'X'
          i_line_header        = 'X'
          i_tab_raw_data       = it_raw
          i_filename           = p_file
        TABLES
          i_tab_converted_data = itab[]
        EXCEPTIONS
          conversion_failed    = 1
          OTHERS               = 2.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
    ENDFORM.                    " UPLOAD_DATA
    *&      Form  DISPLAY_DATA
    *       text
    *  -->  p1        text
    *  <--  p2        text
    FORM display_data .
      LOOP AT itab.
        WRITE : / itab-empid, itab-name, itab-doj.
      ENDLOOP.
    ENDFORM.                    " DISPLAY_DATA
    Hope this helps you.
    Regards,
    Tarun

  • Pls tell me how to upload from excel file to database.

    hello,experts,
    I want to upload data from excel local file to database table created by myself.when I use function
    CALL FUNCTION 'GUI_DOWNLOAD'
    the data in the internal table just become error code data that can not understand.
    who can help me out?
    thanks.

    Hi,
    1st copy the values in XLS into internal table by using function Module:-
    call function 'ALSM_EXCEL_TO_INTERNAL_TABLE'
    exporting
    filename = file_name<it is file path of u r XLS>
    i_begin_col = 1
    i_begin_row = 1
    i_end_col = 250
    i_end_row = 1
    tables
    intern = itab<this structure is same like u r database table>
    exceptions
    inconsistent_parameters = 1
    upload_ole = 2
    others = 3.
    if sy-subrc 0.
    then modify or insert these values to database from internal table:-
    modify <DB table> from itab accepting duplicate keys.
    for file popup use :
    at selection-scree on <screen field>.
    call function 'F4_FILENAME'
    exporting
       program = sy-cprog
       dynnr     = sy-dynnr
    importing
       filename = zfilename.
    here zfilename of type rlgrap-filename.
    and pass this as path in ASLA_EXCEL_TO_INTERNAL_TABLE
    Edited by: vijay Mekala on Dec 29, 2007 12:45 PM

  • Help with data merge from Excel

    I think it's easiest to first explain the project...
    I am working on a print project that has an excel file containing specific data per person. The data gives FirstName, LastName, Picture, About, Phone, etc. per person (over 100 people) I am making a 3 page InDesign template to generate each persons info.
    The problem is the About column of data. The about column contains 2-3 paragraphs of text per cell. These paragraphs need to be formatted as separate paragraphs so that I do not have 1 continuous line of text. When I import the csv or txt (doesn't matter which way I save out the file) InDesign is not reading those paragraph breaks properly and all data after the first cell of About data is missing when I preview. If I remove the spaces in the About cell data it works perfectly.
    I know large spaces in comma delimited data often cause problems (I work in prepress) and we usually remove all extra spaces from cells, but in this instance I need these spaces AND I need them to format properly in my InDesign template. Any ideas or suggestions would be greatly appreciated, and will likely save me a great deal of work.
    I am using CS2.
    Thanks,
    Patty

    I did get your email, and as I posted above, I think Ken's suggestion to use the Rorohiko plugin will be more satisfactory than trying to completely rework your data file (though I don't have a complete picture of the file structure based on the PDF).
    In order to get threaded text you must either flow it in as threaded text, or combine the separate frames. Since the plugin will do the latter in a matter of moments, and preparing the text file for autoflow if it needs major revision or is of any great length could take considerably longer (plus you will then need to run multiple find/change operations to re-format the specially prepared text), I didn't pursue asking for a sample of the data file.
    Should you decide you want to modify the data, you will need to do something like move it into Excel, then most likely concatenate all of the fields that need to remain on a single line (using a special separation character (~, %, ! or other symbol that doesn't otherwise appear anywhere in your data that you can later change to a tab), leaving yourself with only cells for each individual line, and save as tab delimited text. This should give you a text file that looks like:
    Line1 (tab) line2 (tab) line3 (tab) line4
    Line1 (tab) line2 (tab) line3 (tab) line4
    Line1 (tab) line2 (tab) line3 (tab) line4
    Line1 (tab) line2 (tab) line3 (tab) line4
    Place the text file, then run a find change to convert tabs to forced line breaks (not end of paragraph), another to convert forced line breaks immediately followed by paragraph ends (or blank space if that's how it comes in -- I haven't tested to see what an empty cell looks like) to just paragraph ends to eliminate blank lines (I suppose you might also have blank lines in the middle, which would mean running a find change for consecutive forced line breaks with nothing between), and finally one to change your special joiner character to a tab.
    This structure will allow you to use a nested paragraph style to format the different pieces of the directory in one operation, but as you can see it's fairly complicated to execute.
    Peter

Maybe you are looking for

  • Copied Business Role in Solution Manager ITSM

    Hi All This is eunhwa. I have a question regarindg copied business role in Solution Manager ITSM. To copy business role, I copied technical roles Navigation profile, configuration key and PFCT Role ID. And then I copied a business Role. And assign co

  • Why did my ipod do not turn on??

    I have an ipod, i was playing when my ipod turns off and then appear the image with the battery, next i connect my ipod to my computer 30 minutes later i try to turn on my ipod but it was so hot and didn't react.. Help me Please ¡¡¡

  • My battery capacity decreases per charge!!!

    Hi guys I need help, I am very frustrated about this matter , This is my first macbook pro retine late 2013 the latest one out yet 4gb ram baseline model with the dubal core i5. I started playing LOL or League of Legends an online game a few weeks ba

  • A dialog with minimize and maximize buttons

    Hello, Can you please peek at my question in the Swing forum and try to help me (it's a new question, not the one I posted about earlier)? http://forum.java.sun.com/thread.jspa?threadID=758003 Thanks!

  • Internation ACH & Wire encashmnet File

    All, My company wants to implement the integrated payables i.e when it sends the files for the ACH & wrires to the bank, it wants to get a encashmnet file back from the back and upload it into the system and also that how to take care of the forex va