Application Development and Automation 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: 
Read only

Data read issue in unicode

Former Member
0 Likes
380

Hi All,

We have recently upgraded client system from 4.6C to ECC 6.0 unicode system.

My program is reading a file from application server. This file contains the name and addresses of vendors. The address has a field '#' in it.

When we try to execute the statement 'READ DATASET filename INTO itab', it is giving a dump.

If we remove the character '#' from the data, the READ DATASET is successful.

But it is not possible to remove # form such a large data.

I want to know that is there any system by which we can read the special character # in unicpde system without dump.

regards,

Gaurav

2 REPLIES 2
Read only

Former Member
0 Likes
331

Hi,

Split the address field before reading the filename .I think this might solve the issue.Pls reply if any further clarification needed.

Best Regards,

Jayavardhan.

Read only

Former Member
0 Likes
331

Hi ,

In order that program need to read the special characters without failing,

We need to choose addition "NON-UNICODE" for "OPEN DATASET" statement.

The file containing the special characters could not be uploaded if Unicode mode is used.

Instead of hardcoding and changing the code each , We can develop the intelligence in our program in simple manner.


Code example:

parameters: uc  radiobutton group enco default 'X',
            nuc radiobutton group enco.

if uc = 'X'.
  open dataset dsn in text mode for input encoding utf-8.
[OR 
open dataset dsn in text mode for input encoding DEFAULT.
NOTE : In Unicode systems, the default encoding is UTF-8 ]
elseif nuc = 'X'.
open dataset dsn in text mode for input encoding non-unicode.
endif.

In this case check the Non-unicode button

Thank you.