Skip to Content
0
Former Member
Apr 03, 2006 at 02:09 PM

Flexible Date Restriction on Key Figure

22 Views

Hello Gurus,

I have to show in a query 2 different columns with the "first year" and "second year" ammount of sales for each different project.

The problem I have is that each <b>1st year</b> and <b>2nd year</b> of each particular project are different from any other that means that while for project <b>A</b> the <u>1st year is 2005</u> ,for project <b>B</b> the <u>first year is 2001</u>. So I cannot select by a fixed or even a variable date as I need the selection date to change for every line.

The projects are stored in an ODS with a different line for each year, like this:

Proj.___Year___Ammount

A______2005___1000

A______2006___2500

B______2001___ 500

B______2002___2100

In the query I should show

Proj.___1st Year sales____2nd Year sales

A______1000______________2500

B______ 500______________2100

I Thought that the only available solution is to use a virtual key figure in this case. Do you see any other solution ? if not , then a simple ABAP code post will be nicely appreciated.

Thank you very much

Herny