Application Development 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: 

Need ABAP CODE for Replacing Values while loading into ADSO

former_member440909
Discoverer
0 Kudos

Hi All

I have a Scenario as Below:

There are some dump values in the Currency Field from Source System.

Inorder to get rid of that , I have a scenario where i can lookup the Value for Currency Based on Company Code from 0COMP_CODE and Replace the Currency Value Respectively in Transformation and Load into ADSO.

Can anybody Help on this.

Thanks in Advance

5 REPLIES 5

raymond_giuseppi
Active Contributor
0 Kudos
  • Did you analyze why 'there are some dump values in the Currency Field from Source System'?
  • Are you speaking about currency code or currency amount?

0 Kudos

Currency Code

0 Kudos

They are being scanned from a Document and Loaded into ECC System.

0 Kudos

No check are executed in ECC (source system) Hope it's a customer table (Zxxxx) ?

Nevertheless you shouldn't need Abap, in the transformation a simple rule type 'Read Master Data' could meet the requirement. (Correction in source system would be far better than this band-aid on a wooden leg...)

DoanManhQuynh
Active Contributor
0 Kudos

So first you mapping company code and currency from source to currency of target ADSO. chose routine rule for that mapping, in this routine write code to check source currency code if its dummy one then select the currency code from company code like you said, its quite simple. something like:

If src_currency = 'dummy'. "your logic to check dummy currency
select single CURRENCY from /BI0/PCOMP_CODE 
where COMP_CODE = src_companycode 
and OBJVERS = 'A' "Active one 
into result. "here is the replacement
endif.