Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

doubt on BDC field seperator

Former Member
0 Kudos

Hello ,

I am working on the BDC .....

And my upload file is

Nat11 W VKHM Nat 000

its working fine....

CALL FUNCTION 'GUI_UPLOAD'

EXPORTING

FILENAME = 'c:\bdc1.TXT'

FILETYPE = 'ASC'

HAS_FIELD_SEPARATOR = '#'

But I want to remove tab and want to place the "#" as field separator

what I have to do ....

1 REPLY 1

former_member156446
Active Contributor
0 Kudos

Hi Sunil

gui_upload will not work in background.. so make sure with ur FC will this program be run in background...if so you need to change the FM..


      CALL FUNCTION 'GUI_UPLOAD'
           EXPORTING
                FILENAME            = l_file
                HAS_FIELD_SEPARATOR = 'X'
           TABLES
                DATA_TAB            = input_tab
           EXCEPTIONS
                CONVERSION_ERROR    = 1
                INVALID_TABLE_WIDTH = 4
                INVALID_TYPE        = 5
                NO_BATCH            = 6
                UNKNOWN_ERROR       = 7
                OTHERS              = 8.
      IF SY-SUBRC <> 0.
        SKIP.
*        FORMAT COLOR COL_NEGATIVE INTENSIFIED ON.
        WRITE: /1 '-> Error occured during upload process of file:',
               /1 '->', IFILE,
               /1 '-> Program terminated'.
        FORMAT RESET.
        STOP.
      ENDIF.
    endif.

also check this [PDF doc|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/80928174-0a01-0010-42aa-a88b3fedb648] for more details

Edited by: Jackandjay on Jun 14, 2008 11:53 AM