2008 Mar 11 6:47 AM
Hi,
i am trying to read a tab delimited file from presentation server.cani use WS_upload.
how to split the data afterwards?
plz reply,
Thanks,
Anand.
Hi,
i am trying to read a tab delimited file from presentation server.cani use WS_upload.
how to split the data afterwards?
plz reply,
Thanks,
Anand.
2008 Mar 11 6:50 AM
Hi
Ws_upload is obsolete...
Use GUI_upload instead....passing
tab as delimiter parameter..
Internal table u will pass to this module shud have same structure as that of file....so the data will be automatically uploaded to table...no need to specific split..
Edited by: Dhananjay Patil on Mar 11, 2008 7:51 AM
2008 Mar 11 6:52 AM
Hi,
use the function module gui_upload instead of using ws_upload(it is obsolete one).
in gui_upload there is an exporting prameter has_field_seperater pass the value 'X'
example:
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
FILENAME = PATH
FILETYPE = 'ASC'
HAS_FIELD_SEPARATOR = 'X'
HEADER_LENGTH = 0
TABLES
DATA_TAB = ITAB
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.
rgds,
bharat.
2008 Mar 11 6:53 AM
Hi,
Read the documentation of WS_UPLOAD. If all the values has been given to this function module, then there is no need to split the data once again. It automatically gives you the values in an intenal table.
caution: the function module WS_UPLOAD IS obsolete. Instead of it you can use GUI_UPLOAD. The functionality of both the function modules are one and same.