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: 

Seeing '#' along side a fieldvalue while trying to upload

Former Member
0 Kudos

Hi Gurus,

I am trying to upload two flat files into two respective internal tables and using a logic i am trying to bring the data from two files into one and download it.When i am uploading the field contents i can see that '#' is attached after the field value for all the entries of the table.

Thanks in Advance,

Sashi.

1 ACCEPTED SOLUTION

Former Member
0 Kudos

<b>FILETYPE = 'ASC'

HAS_FIELD_SEPARATOR = 'X'</b>

CALL FUNCTION 'GUI_UPLOAD'

EXPORTING

filename = v_filename_string

filetype = 'ASC'

has_field_separator = 'X'

  • HEADER_LENGTH = 0

  • READ_BY_LINE = 'X'

dat_mode = ''

  • IMPORTING

  • FILELENGTH =

  • HEADER =

TABLES

data_tab = i_text_data

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 ID sy-msgid TYPE sy-msgty NUMBER sy-msgno

WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.

ENDIF.

5 REPLIES 5

Former Member
0 Kudos

Hi sashi

I think that "#" is the field separator being used for the file. Since, ABAP editor cannot recognise the ASCII value for say tab delimited file, it will be displayed as "#".

~ Ranganath

PS : Reward points for all useful answers !

Former Member
0 Kudos

<b>FILETYPE = 'ASC'

HAS_FIELD_SEPARATOR = 'X'</b>

CALL FUNCTION 'GUI_UPLOAD'

EXPORTING

filename = v_filename_string

filetype = 'ASC'

has_field_separator = 'X'

  • HEADER_LENGTH = 0

  • READ_BY_LINE = 'X'

dat_mode = ''

  • IMPORTING

  • FILELENGTH =

  • HEADER =

TABLES

data_tab = i_text_data

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 ID sy-msgid TYPE sy-msgty NUMBER sy-msgno

WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.

ENDIF.

0 Kudos

Thanks It worked....

Bye,

Sashi...

former_member188827
Active Contributor
0 Kudos

u can remove # in loop endloop.

first move da value to a type c variable.

den use stmt

replace '#' in zch with space.

condense zch.

move da value back to original field from type c variable.

Former Member
0 Kudos

in GUI_UPLOAD fm use field seperator as '#' this will solve problem