‎2008 Jul 14 11:16 AM
Hi,
I have an xstring which needs to be split into chunks of 1024 bytes.
how to achieve this?
Thanks in advance,
ajay
‎2008 Jul 14 11:18 AM
‎2008 Jul 14 11:40 AM
i saw the thread previously.
The strlen function does not work for xstrings.
‎2008 Jul 14 11:38 AM
SPLIT dobj AT sep INTO { {result1 result2} | {TABLE resulttab} } (IN {BYTE Or CHARACTER} MODE).
check below syntax for split
hear you can give number of bytes you need to split.
‎2008 Jul 14 11:48 AM
Thanks for the reply.
I need to split the xstring based on size and not based on a seperator.
with regards,
ajay
‎2008 Jul 14 1:58 PM
use FM
SCMS_XSTRING_TO_BINARY
the table you will pass to BINARY_TAB has to have the following definition.
constants: line_size type i value 1024.
data: begin of binary_tab occurs 0,
raw(line_size) type x,
end of binary_tab .
‎2014 Sep 05 4:28 PM
HI Durairaj,
SCMS_XSTRING_TO_BINARY doesn't work as system on the other end is unable to put the xstring back together which was split using the above FM.
Its old post, but would appreciate more clarity.
Any alternative way of splitting the Xstring.
Thanks,
Vikram
‎2008 Jul 14 2:02 PM
‎2014 Sep 05 4:27 PM