cancel
Showing results for 
Search instead for 
Did you mean: 

Need to load blank field value

Former Member
0 Kudos

Hi,

We are loading the data from ECC. And today the load failed at the DSO activation step due to a special character in one of the fields. The field is called Item Text and it is of char 60. The value in that field is # at the PSA level and it is been understood that ! and # are not allowed as the first character of the string and this failed because of that. when we approached the ECC team for this field value they informed that the value has been deleted in the source system. Now i would like to understand is: if go to PSA and delete the # and save the record and try to load into DSO, what will happen. Will it again take the value as # due to the field being blank or will it load.

Please let me know.

Regards

Vijay

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Vijay,

If my understanding is right, if you change the record in PSA now and load the data from PSA to your DSO, the changed record will be loaded into DSO. If you remove # in PSA, the loaded data in DSO doesnot contain # value.

Regards,

KK.

Former Member
0 Kudos

You have to first delete this request from your DSO

Now OPen PSA and edit the record.

Note down the value in this filed

Delete the whole data and type the value that you have noted down without the # and save it.

Note : You might face same issue in another record when you load again.

Also set your RSKC to ALL_CAPITALS

Former Member
0 Kudos

Hi,

The value for this field in the source is blank. Thats what the ECC team confirmed. If i wanted to change this to another value we could have done, but if i open that record and delete the # and again save it will it not create the # again in that field. This is happening for only 1 record. When the source itself is saying that there is no value for this field then how do we allow only blank to the DSO? Any help is great.

Regards

Vijay

Former Member
0 Kudos

Hi Vijay,

try this code:


DATA: p_ix LIKE sy-index.
CONSTANTS: c_allowed (100) TYPE c
value 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_1234567890'. "define your allowed characters
RESULT = SOURCE_FIELDS-Your_field_name.
TRANSLATE RESULT TO UPPER CASE.
DO 60 TIMES
p_ix = sy-index - 1.
If RESULT+p_ix(1) CO c_allowed.
* allowed character do nothing
ELSE.
* character is not allowed replace with blank
RESULT+p_ix(1) = ' '.
ENDIF.
ENDDO.

This code will help you in future cases too if there is a character which is not allowed or invalid.

Code example is like in book "ABAP Development for SAP NetWeaver BI u2013 User Exits and BadIs"

by Dirk Herzog which includes many such useful examples.

I use it my self and it is working great.

Regards

Andreas