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

Transformation ID - Case Insensitive mapping?

rb
Contributor
0 Likes
1,458

Hello guys,

i want to map a JSON string to a ABAP structure. Because it´s a relative simple 1 : 1 mappnig I dont want to create a simple transformation.

Only problem is that the JSON is generated externally an the attribute key is camel case :


{"custRef" : "123", "projRef" : "Project"}

When i map with

CALL TRANSFORMATION id

SOURCE XML lv_json_string

RESULT custref = lv_custref.

Then there is no result. If i change the JSON keys to uppercase the mapping is OK.

Some ideas how to get an case insensitive mapping without own ST?

Bye Richard

1 ACCEPTED SOLUTION
Read only

rb
Contributor
0 Likes
739

Found a solution in DEMO Report from SAP.

SE38 DEMO_JSON_NAMES_TO_UPPER

Hello guys,

i want to map a JSON string to a ABAP structure. Because it´s a relative simple 1 : 1 mappnig I dont want to create a simple transformation.

Only problem is that the JSON is generated externally an the attribute key is camel case :


{"custRef" : "123", "projRef" : "Project"}

When i map with

CALL TRANSFORMATION id

SOURCE XML lv_json_string

RESULT custref = lv_custref.

Then there is no result. If i change the JSON keys to uppercase the mapping is OK.

Some ideas how to get an case insensitive mapping without own ST?

Bye Richard

1 REPLY 1
Read only

rb
Contributor
0 Likes
740

Found a solution in DEMO Report from SAP.

SE38 DEMO_JSON_NAMES_TO_UPPER