Skip to Content
0

DTP Filter routine

Feb 27 at 02:00 PM

55

avatar image
Former Member

dtp-filter.jpg

Hi Experts,

I checked in the forum but I haven't see any suitable solution for my requirement so requesting for help.

I am having a DTP full load and in that I have 2 selections - Company code and plant.

Company code I am giving 3 values - ch01,ch02,ch03 and based on this plants should be restricted.And in furture we may add new company codes.

In CH03 i want only 2 plants - PL01,PL02 and that is why I am going for routine in DTP. So that I can fetch all the plants for CH01,CH02 and 2 plants for CH03.

I have created the routine for PLANT but struggling to get values of company code in that routine so that I can fetch the relevant plants.

Please advise.

dtp-filter.jpg (99.8 kB)
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

3 Answers

avatar image
Former Member Feb 27 at 02:03 PM
0

Hi Experts,

I am not getting any values in l_t_range

Share
10 |10000 characters needed characters left characters exceeded
Sebastian Gesiarz Mar 01 at 11:09 AM
0

Hi,

I would suggest you to filter COMPCODE/PLANT combinations in transformation routine / AMDP(recommended on HANA) and COMPCODE's in static DTP Filter.

Way to go:

  1. Filter company codes in static DTP filter.
  2. Insert something like below in ABAP start routine:
DELETE SOURCE_PACKAGE WHERE 0COMPCODE EQ 'CH03' AND PLANT NE 'PL01' AND PLANT NE 'PL02'.

Or something similar as a select restriction in AMDP.

Kind regards,

Sebastian

Share
10 |10000 characters needed characters left characters exceeded
Mario Tibollo Mar 02 at 09:08 AM
0

Why don't you just use two DTP's?

one with restriction on company code ch01 and ch02

a second one with restriction on company code ch03 and plants pl01, pl02.

should get you the desired data in your datatarget.

M.

Share
10 |10000 characters needed characters left characters exceeded