Comma seperated file uploading

Hi ,
i want to upload comma seperated file into sap.
iam using 'GUI_UPLOAD' fm.
problem is flat file currency field it is also contains comma.
i can't change file type comma to tab.
How can i upload currency fields with comma.
Regards,
Suresh.

You can upload your file into a string table. Now split it:
split uploadtab at ',' into table items.
if you have
a,b,c,11,d,e,f
your tables items contains 7 elements now.
if you have
a,b,c,11,22,d,e,f
your table contains 8 elements now. In that case you now that you have splitted a number with a comma and need to do some actions, e.g. merge elements 4 and 5 together to get 11,22 again and shift the 6th to 5th, the 7th to 5th and the 8th to 7th element.
After that you number is again in item 4.
An easier way is to enforce you customer to put values into apostrophes or quotes. If this is not possible, you have to check if an unwanted split was taken in place and act as shown above.
But: this will work only if one item with a comma in between. If oyu have more components you can not evaulate where the unwanted split is in effect.

Similar Messages

  • Generate an Upload the current table to a comma seperated file

    Hi Freaks,
    i want to generate a comma seperated file from the current table (which was modified in the current Apex Window) and also upload the file to a file server.
    What is the best practice?
    Thanks a lot
    Wolle

    Hello Wolle,
    In the APEX SQL Workshop -> Object browser, when you select a table, and select the Data tab. There's a link at the bottom of the table, "Download". This will automatically generate a csv file for you.
    Alternatively you can use a client like toad or sql developer to generate a csv.
    Greetings,
    Rutger
    http://rutgerderuiter.blogspot.com/
    ===============================================================================
    You can reward this reply by marking it as either Helpful or Correct ;-)

  • 9iJSP Report output to a comma seperated file

    Hi,
    Is it possible to create a comma seperated file with output data from a 9iJSP report. If yes, can anyone tell me how ??
    thanks in advance
    Unmesh

    Hello Unmesh,
    If your JSP report has a paper layout, then you can use Reports Builder or the client/servlet/runtime executables to generate the paper layout to CSV formatted output with the DESFORMAT=DELIMITEDDATA and DELIMITER=, command-line options. If you have only a web layout , it will generate its output only in HTML format.
    You can add a paper/web layout to your JSP report, if it already doesn't have one, by opening it in Reports Builder, and inserting a report block in the paper layout view/web source view. This JSP report can then be used both to generate to CSV format using rwservlet, and to the web when deployed as a JSP.
    Thanks,
    The Oracle Reports Team.

  • Comma Seperated Files

    I am trying to read in data from a .CSV file.
    The CSV file contains a list of questions and answers in the
    format;
    Question, option1, option2,option3,option4, correct answer
    My problem is that I can get the whole line into an array but
    I can't find a way of getting each element of the comma seperated
    file into a multi dimensioned array.
    I need to be able to use MyArray[1,1] is equal to
    Question and MyArray[1,2] is equal to
    option1 etc etc
    Hope this makes sense
    Paul

    In your routine you have two loops.
    Either one will work on thier own but as soon i nest them
    then it just stops working........
    The below data is stored as a Data.csv file (Obviously it
    contains a lot more these are the first 3 records.) **Can't count =
    4 records lol)
    ,,B,,,,Lorry,,,,,X,,,,,CC5001 ,Mark one answer,,under 7.5
    tonnes maximum authorised mass,over 7.5 tonnes maximum authorised
    mass,over 7.5 metres overall height,under 7.5 metres overall
    height,,,1111,This sign means no entry for goods
    vehicles,TS4619.eps,CC5001.gif ,Vehicle Weights and Dimensions
    ,,B,,,,Lorry,,,,,X,,,,,CC5002 ,Mark one answer,,either the
    left-hand or middle lane,only the left-hand lane,only the middle
    lane,any of the lanes,,,1111,Your lorry is over 7.5 tonnes maximum
    authorised mass. This sign means you may use,TS4545.eps,CC5002.gif
    ,Vehicle Weights and Dimensions
    ,,C,,,,Lorry,,,,,,X,,,,CC5003,Mark one answer,,30 mph,40
    mph,50 mph,60 mph,,,1111,You are driving a lorry with a maximum
    authorised mass of 7 tonnes. What is the maximum speed limit on a
    single carriageway?,,,Vehicle Weights and Dimensions
    ,,B,,,,Lorry,,,,,X,,,,,CC5004,Mark one answer,,30 mph,40
    mph,50 mph,60 mph,,,1111,What is the national speed limit on a
    single carriageway road for a rigid lorry weighing more than 7.5
    tonnes maximum authorised mass?,,,Vehicle Weights and
    Dimensions

  • How to make comma seperated file

    hi
    I have a select statement that looks like below. I want to make comma seperated file for the selected columns. How to write it?
    SELECT MM.DAL_NUMBER,
    '19-NOV-2009' as WSS_CE,
    CPN_INT,
    TRADE_DATE,
    MX_DATE "LAST_DATE",
    CUSTOMER_SPECIF CUST_GID,
    NAME_SHORT CUST_NAME_SHORT
    from my_table;
    if you could provide me with exact query.
    Thanks

    Slightly more generic approach...
    As sys user:
    CREATE OR REPLACE DIRECTORY TEST_DIR AS '\tmp\myfiles'
    GRANT READ, WRITE ON DIRECTORY TEST_DIR TO myuser
    /As myuser:
    CREATE OR REPLACE PROCEDURE run_query(p_sql IN VARCHAR2
                                         ,p_dir IN VARCHAR2
                                         ,p_header_file IN VARCHAR2
                                         ,p_data_file IN VARCHAR2 := NULL) IS
      v_finaltxt  VARCHAR2(4000);
      v_v_val     VARCHAR2(4000);
      v_n_val     NUMBER;
      v_d_val     DATE;
      v_ret       NUMBER;
      c           NUMBER;
      d           NUMBER;
      col_cnt     INTEGER;
      f           BOOLEAN;
      rec_tab     DBMS_SQL.DESC_TAB;
      col_num     NUMBER;
      v_fh        UTL_FILE.FILE_TYPE;
      v_samefile  BOOLEAN := (NVL(p_data_file,p_header_file) = p_header_file);
    BEGIN
      c := DBMS_SQL.OPEN_CURSOR;
      DBMS_SQL.PARSE(c, p_sql, DBMS_SQL.NATIVE);
      d := DBMS_SQL.EXECUTE(c);
      DBMS_SQL.DESCRIBE_COLUMNS(c, col_cnt, rec_tab);
      FOR j in 1..col_cnt
      LOOP
        CASE rec_tab(j).col_type
          WHEN 1 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_v_val,2000);
          WHEN 2 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_n_val);
          WHEN 12 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_d_val);
        ELSE
          DBMS_SQL.DEFINE_COLUMN(c,j,v_v_val,2000);
        END CASE;
      END LOOP;
      -- This part outputs the HEADER
      v_fh := UTL_FILE.FOPEN(upper(p_dir),p_header_file,'w',32767);
      FOR j in 1..col_cnt
      LOOP
        v_finaltxt := ltrim(v_finaltxt||','||lower(rec_tab(j).col_name),',');
      END LOOP;
      --  DBMS_OUTPUT.PUT_LINE(v_finaltxt);
      UTL_FILE.PUT_LINE(v_fh, v_finaltxt);
      IF NOT v_samefile THEN
        UTL_FILE.FCLOSE(v_fh);
      END IF;
      -- This part outputs the DATA
      IF NOT v_samefile THEN
        v_fh := UTL_FILE.FOPEN(upper(p_dir),p_data_file,'w',32767);
      END IF;
      LOOP
        v_ret := DBMS_SQL.FETCH_ROWS(c);
        EXIT WHEN v_ret = 0;
        v_finaltxt := NULL;
        FOR j in 1..col_cnt
        LOOP
          CASE rec_tab(j).col_type
            WHEN 1 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_v_val);
                        v_finaltxt := ltrim(v_finaltxt||',"'||v_v_val||'"',',');
            WHEN 2 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_n_val);
                        v_finaltxt := ltrim(v_finaltxt||','||v_n_val,',');
            WHEN 12 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_d_val);
                        v_finaltxt := ltrim(v_finaltxt||','||to_char(v_d_val,'DD/MM/YYYY HH24:MI:SS'),',');
          ELSE
            v_finaltxt := ltrim(v_finaltxt||',"'||v_v_val||'"',',');
          END CASE;
        END LOOP;
      --  DBMS_OUTPUT.PUT_LINE(v_finaltxt);
        UTL_FILE.PUT_LINE(v_fh, v_finaltxt);
      END LOOP;
      UTL_FILE.FCLOSE(v_fh);
      DBMS_SQL.CLOSE_CURSOR(c);
    END;This allows for the header row and the data to be written to seperate files if required.
    e.g.
    SQL> exec run_query('select * from emp','TEST_DIR','output.txt');
    PL/SQL procedure successfully completed.Output.txt file contains:
    empno,ename,job,mgr,hiredate,sal,comm,deptno
    7369,"SMITH","CLERK",7902,17/12/1980 00:00:00,800,,20
    7499,"ALLEN","SALESMAN",7698,20/02/1981 00:00:00,1600,300,30
    7521,"WARD","SALESMAN",7698,22/02/1981 00:00:00,1250,500,30
    7566,"JONES","MANAGER",7839,02/04/1981 00:00:00,2975,,20
    7654,"MARTIN","SALESMAN",7698,28/09/1981 00:00:00,1250,1400,30
    7698,"BLAKE","MANAGER",7839,01/05/1981 00:00:00,2850,,30
    7782,"CLARK","MANAGER",7839,09/06/1981 00:00:00,2450,,10
    7788,"SCOTT","ANALYST",7566,19/04/1987 00:00:00,3000,,20
    7839,"KING","PRESIDENT",,17/11/1981 00:00:00,5000,,10
    7844,"TURNER","SALESMAN",7698,08/09/1981 00:00:00,1500,0,30
    7876,"ADAMS","CLERK",7788,23/05/1987 00:00:00,1100,,20
    7900,"JAMES","CLERK",7698,03/12/1981 00:00:00,950,,30
    7902,"FORD","ANALYST",7566,03/12/1981 00:00:00,3000,,20
    7934,"MILLER","CLERK",7782,23/01/1982 00:00:00,1300,,10The procedure allows for the header and data to go to seperate files if required. Just specifying the "header" filename will put the header and data in the one file.
    Adapt to output different datatypes and styles are required.

  • Comma Seperated File

    Is there a way that I can bring a comma seperated file into an oracle table?

    If you are using Oracle 9i and above, you may also want to consider using external tables.
    http://download-west.oracle.com/docs/cd/A91202_01/901_doc/server.901/a90192/ch11.htm#1656

  • Create datastore for complex comma seperated file

    I am trying to integrate a comma seperated file to an Oracle database. The files contain multiple record types each of which have different number of fields and a different order of datatypes within those fields. The order that the records types are listed in the file determines the relationship between them, e.g.
    The file could contained the following record types in the order shown:
    Segment
    Fixture
    Position
    Position
    Segment
    Segment
    Fixture
    Position
    Position
    Position
    So there is a parent-child relationship between the Segement record and the Fixture record that immediately follows it and similarly the position records are child records to the Fixture record.
    How can I create datastores that represents this relationship when there is no parent field in the child record types?

    I dont think ODI would be able to help you much with Out of the box functionality. You will need to modify the LKM (SQLLDR) to achieve this.
    The following entry illustrates the logic:
    [http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:7526680049479]
    Hope that helps

  • Send mail as comma seperated file from abap

    Hi,
    i need to send mail from my program...as a comma seperated file...can u help me out.
    regards
    shankar

    See function module SO_NEW_DOCUMENT_ATT_SEND_API1, there is an example in the documentation. The example is for a .BMP file but you should be able to use the similar code for a text file (you might need to use object RAW). The content of comma-separated file must be in an internal table when you'll call this function module.
    There are also lots of examples available all over the Internet, use search by FM name.

  • Upload  comma seperated file

    Hi,
    I have to upload a text file which  has 12 fields seperated by commas and each of the character field is enclosed by quotes(" ").I tried uploading using GUI_UPLOAD but it is going for short dump.
    First row of the file is as below:
    1,"ALU",0,"7","21-MAY-2008 15",,"000017088656","00919074","L-130912-02-001","05-Feb-2007",0.70,""
    I used the FM as below:
      CALL FUNCTION 'GUI_UPLOAD'
         EXPORTING
           FILENAME                      = fileup
         FILETYPE                      = 'ASC'
         HAS_FIELD_SEPARATOR           = 'X'
         HEADER_LENGTH                 = 0
         READ_BY_LINE                  = 'X'
         DAT_MODE                      = ' '
         CODEPAGE                      = ' '
         IGNORE_CERR                   = ABAP_TRUE
         REPLACEMENT                   = '#'
         CHECK_BOM                     = ' '
         VIRUS_SCAN_PROFILE            =
         NO_AUTH_CHECK                 = ' '
       IMPORTING
         FILELENGTH                    =
         HEADER                        =
         TABLES
           DATA_TAB                      = i_REF
       EXCEPTIONS
    Please solve this problem

    Hi,
    try to use the quotes in the below way..
    and maintain the paramets as CSV as well....
    loop at i_final_data_tmp into wa_final_data_tmp.
       concatenate :
              `"` wa_final_data_tmp-f1  `",`
              `"` wa_final_data_tmp-f2  `",`
              `"` wa_final_data_tmp-f3  `",`
              `"` wa_final_data_tmp-f4  `",`
              `"` wa_final_data_tmp-f5  `",`
              `"` wa_final_data_tmp-f6  `",`
              `"` wa_final_data_tmp-f7  `",`
              `"` wa_final_data_tmp-f8  `",`
              `"` wa_final_data_tmp-f9  `",`
              `"` wa_final_data_tmp-f10 `"`.
       append wa_csv_data to i_csv_data.
       clear wa_csv_data.
    endloop.

  • Function module to read Comma Seperated File (CSV)

    Hi,
    Is there any Function module to read CSV file from presentation server or Application server?
    Regards,
    Madhu

    Hi madhukeshwar,
    1. Exactly for this purpose,
    i have developed an independent FORM
    where we give inputs
    a) file name (eg. abcd.txt)
    b) separator (eg , COMMA in your case)
    c) internal table (eg. t001)
    2. It will provide the data
    in proper format
    (no matter what the separator)
    (it can work with any kind of separator)
    3. just copy paste in new program.
    REPORT abc.
    change your table declaration and file name
    DATA : t001 LIKE TABLE OF t001 WITH HEADER LINE.
    PERFORM myupload TABLES t001 USING 'd:\t001.txt' ','.
    BREAK-POINT.
    in debug see t001
    INDEPENDENT FORM
    FORM myupload TABLES orgtab
    USING filename separator.
    Data
    DATA : BEGIN OF itab OCCURS 0,
    myline(1000) TYPE c,
    END OF itab.
    DATA : extension(5) TYPE c.
    DATA : name(100) TYPE c.
    DATA : newfilename TYPE string.
    Step 1
    CALL FUNCTION 'GUI_UPLOAD'
    EXPORTING
    filename = filename
    TABLES
    data_tab = itab.
    Step 2
    LOOP AT itab.
    REPLACE ALL OCCURRENCES OF separator IN itab-myline WITH
    cl_abap_char_utilities=>horizontal_tab.
    MODIFY itab.
    ENDLOOP.
    Step 3
    DATA : path LIKE pcfile-path.
    path = filename.
    CALL FUNCTION 'PC_SPLIT_COMPLETE_FILENAME'
    EXPORTING
    complete_filename = path
    CHECK_DOS_FORMAT =
    IMPORTING
    DRIVE =
    extension = extension
    name = name
    NAME_WITH_EXT =
    PATH =
    EXCEPTIONS
    invalid_drive = 1
    invalid_extension = 2
    invalid_name = 3
    invalid_path = 4
    OTHERS = 5
    Step 4
    newfilename = filename.
    REPLACE name IN newfilename WITH 'temp'.
    CALL FUNCTION 'GUI_DOWNLOAD'
    EXPORTING
    BIN_FILESIZE =
    filename = newfilename
    TABLES
    data_tab = itab
    FIELDNAMES =
    Step 5
    CALL FUNCTION 'GUI_UPLOAD'
    EXPORTING
    filename = newfilename
    has_field_separator = 'X'
    TABLES
    data_tab = orgtab.
    ENDFORM. "myupload
    3.
    regards,
    amit m.

  • Excel comma seperated .csv files save as semicolon seperated

    Hi
    I work with excel 360 student version danish and i'm trying to convert an siemens .xmls generated file to an .csv comma seperated file but excel save it as an semi colon though it's written in help file it should save it as an comma seperated file.
    Any solution on that what i would call a bug thats been there for over a year?

    Kent, I think you're posting a complaint about Excel, which is off topic for the TechNet Website Feedback forum. The best place to post that would be over at http://answers.microsoft.com in the office section.  Below is some boilerplate that
    I've written up that might also help you.
    Thanks,
    Mike
    Unfortunately your post is off topic here, in the TechNet Site Feedback forum, because it is not Feedback about the TechNet Website or Subscription.  This is only one forum among the many that are on the TechNet Discussion Forums, and given
    your post, you likely chose the wrong forum.  This is a standard response I’ve written up in advance to help many people (thousands, really.) who post their question in this forum in error, but please don’t ignore it.  The links I share below I’ve
    collected to help you get right where you need to go with your issue.
    For technical issues with Microsoft products that you would run into as an
    end user of those products, one great source of info and help is
    http://answers.microsoft.com, which has sections for Windows, Hotmail, Office, IE, and other products. Office related forums are also here:
    http://office.microsoft.com/en-us/support/contact-us-FX103894077.aspx
    For Technical issues with Microsoft products that you might have as an
    IT professional (like technical installation issues, or other IT issues), you should head to the TechNet Discussion forums at
    http://social.technet.microsoft.com/forums/en-us, and search for your product name.
    For issues with products you might have as a Developer (like how to talk to APIs, what version of software do what, or other developer issues), you should head to the MSDN discussion forums at
    http://social.msdn.microsoft.com/forums/en-us, and search for your product or issue.
    If you’re asking a question particularly about one of the Microsoft Dynamics products, a great place to start is here:
    http://community.dynamics.com/
    If you really think your issue is related to the subscription or the TechNet Website, and I screwed up, I apologize!  Please repost your question to the discussion forum and include much more detail about your problem, that could include screenshots
    of the issue (do not include subscription information or product keys in your screenshots!), and/or links to the problem you’re seeing. 
    If you really had no idea where to post this question but you still posted it here, you still shouldn’t have because we have a forum just for you!  It’s called the Where is the forum for…? forum and it’s here:
    http://social.msdn.microsoft.com/forums/en-us/whatforum/
    Moving to off topic. 
    Thanks, Mike
    MSDN and TechNet Subscriptions Support
    Did Microsoft call you out of the blue about your computer?
    No, they didn't.

  • Regarding semi colon seperated file for upload

    Hi Friends,
    I have an requirement where in to upload text files from presentation server which is semi colon seperated.
    I am able to upload to the internal table using GUI_UPLOAD, but the problem is sometimes in the text file one line can be in two lines where in the system takes it as two different lines of records.
    Could anyone suggest a logic to correct this.

    Hi,
    Use the below blog, it may help you...
    http://abaplog.wordpress.com/2007/08/15/reading-a-comma-delimited-file-in-abap-aka-csv-file/
    http://www.kyusl.com/ilya/csv.html
    You may need to adopt it to parse semicolon.
    Regards
    Karthik D

  • How to store Comma Seperated Value in a File with Jsp

    Hai friends,
    I need to get all the filed values like Empname,salary ,location..........
    and at the end of jsp page i have to put a browse button when i choose a file using theis browse button the total content in the form shoud store in that file as comma seperated values.

    1. Create JSP
    2. When you click the button call the event that saves the data in CSV format
    Your question is so broad, I don't have exact answer for you.
    What have you done so far?
    The man with blues.

  • Downloading into a text file with comma seperation

    hey experts,
    well i want to download various fields of an internal table into a text file.but the hitch is that all the columns should be seperated by a comma.something like csv.
    could you please help me with this.?
    i have tried using gui download but the seperator field was not working.
    thanks in advance...
    regards,
    sandra.

    hey sandra,
    for comma seperation and downloading ,you can use the following fm.
    here the i_field seperator should be given as "," as in ur case.
    i_tab3 is the table from which the values are being fetched.
    and i_tab2 is the table conatining the comma seperated values.
    CALL FUNCTION 'SAP_CONVERT_TO_TEX_FORMAT'
       EXPORTING
         I_FIELD_SEPERATOR          = ','
      I_LINE_HEADER              =
      I_FILENAME                 =
      I_APPL_KEEP                = ' '
       TABLES
         I_TAB_SAP_DATA             = I_TAB3
       CHANGING
        I_TAB_CONVERTED_DATA       = I_TAB2
    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.
    after this u can use the gui download fm as required.
    CALL FUNCTION 'GUI_DOWNLOAD'
    EXPORTING
      BIN_FILESIZE                    =
        FILENAME                        = TESTFILNA
      FILETYPE                        = 'ASC'
      APPEND                          = ' '
        WRITE_FIELD_SEPARATOR           = 'x'
      HEADER                          = '123'
      TRUNC_TRAILING_BLANKS           = ' '
      WRITE_LF                        = 'X'
      COL_SELECT                      = ' '
      COL_SELECT_MASK                 = ' '
      DAT_MODE                        = ' '
      CONFIRM_OVERWRITE               = ' '
      NO_AUTH_CHECK                   = ' '
      CODEPAGE                        = ' '
      IGNORE_CERR                     = ABAP_TRUE
      REPLACEMENT                     = '#'
      WRITE_BOM                       = ' '
      TRUNC_TRAILING_BLANKS_EOL       = 'X'
      WK1_N_FORMAT                    = ' '
      WK1_N_SIZE                      = ' '
      WK1_T_FORMAT                    = ' '
      WK1_T_SIZE                      = ' '
      WRITE_LF_AFTER_LAST_LINE        = ABAP_TRUE
    IMPORTING
      FILELENGTH                      =
    TABLES
          DATA_TAB                      = I_TAB2
      FIELDNAMES                      =
    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.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    hope this helps u.
    do reward points if useful.....:-)

  • Passing data to different internal tables with different columns from a comma delimited file

    Hi,
    I have a program wherein we upload a comma delimited file and based on the region( we have drop down in the selection screen to pick the region).  Based on the region, the data from the file is passed to internal table. For region A, we have 10 columns and for region B we have 9 columns.
    There is a split statement (split at comma) used to break the data into different columns.
    I need to add hard error messages if the no. of columns in the uploaded file are incorrect. For example, if the uploaded file is of type region A, then the uploaded file should be split into 10 columns. If the file contains lesser or more columns thenan error message should be added. Similar is the case with region B.
    I do not want to remove the existing split statement(existing code). Is there a way I can exactly pass the data into the internal table accurately? I have gone through some posts where in they have made use of the method cl_alv_table_create=>create_dynamic_table by passing the field catalog. But I cannot use this as I have two different internal tables to be populated based on the region. Appreciate help on this.
    Thanks,
    Pavan

    Hi Abhishek,
    I have no issues with the rows. I have a file with format like a1,b1,c1,d1,e1, the file should be uploaded and split at comma. So far its fine. After this, if the file is related to region A say Asia, then it should have 5 fields( as an example). So, all the 5 values a1,b1..e1 will be passed to 5 fields of itab1.
    I also have region B( say Europe)  whose file will have only 4 fields. So, file is of the form a2,b2,c2,d2. Again data is split at comma and passed to itab2.
    If some one loads file related to Asia and the file has only 4 fields  then the data would be incorrect. Similar is the case when someone tries to load Europe file with 5 fields related data. To avoid this, I want to validate the data uploaded. For this, I want to count the no. of fields (seperated by comma). If no. of fields is 5 then the file is related to Asia or if no. of fields is 4 then it is Europe file.
    Well, the no. of commas is nothing but no. of fields - 1. If the file is of the form a1,b1..e1 then I can say like if no. of commas = 4 then it is File Asia.But I am not sure how to write a code for this.Please advise.
    Thanks,
    Pavan

Maybe you are looking for

  • Old hard drive, New MacBook

    Hi, I have just purchased a new Aluminium MacBook to replace my previous white plastic MacBook. In the old MacBook I had a 250GB with OSX 10.5 from WD which I installed myself however when I put this into the new metal MacBook it just keeps restartin

  • I have aproblem down loading ADOBE READER can you help

    I am having difficulty in down loading ADOBE READER can you advice the course of actio I need to take to down load this programme Thank you for your assistance Raymond G Whysall

  • How to Print the smartform repeatedly

    Hello Friends, Let me say, In my selection screen I am giving the label count as 5 and execute, I get a print options popup window where I can mention how many copies I need to print. If I mention 2 here, then I should get 2 sets of 5 labels to be pr

  • How to Start/Stop manually an oracle 9i database with a bat file?

    Hi; I have a manual Start/Stop of the db. How can i Start/Stop the 9i database all services with a batch file (windows 2000) ? All in one batch files ( One for Start & one for Stop)(Including listener) thanks for your answer !

  • Case of the missing Safari preference icons...

    A couple weeks ago, I attempted to download an extension for Safari (unfortunately, I can't remember the name), and there wasn't any indiciation that it was being downloaded.  Upon quitting Safari immediately afterward, when I opened up Safari's pref