Technology Blogs by Members
Explore a vibrant mix of technical expertise, industry insights, and tech buzz in member blogs covering SAP products, technology, and events. Get in the mix!
cancel
Showing results for 
Search instead for 
Did you mean: 
Former Member
8,068

Recently, I have experienced something while modeling HANA information view that I want to share with everyone.


Tested with HANA Revision - SPS 08 80/82


Case:

Dynamic Filter for projection with current Fiscal Year and Fiscal Period.


Method:

In order to filter it dynamically I decided to use input parameter. There are different parameter types that we can use to do this. I decided to use following "Derived from table" type as shown below:



Challenge:

When filtering column then it displays list of values from the same HANA information view and we can select the date. Now, as the requirement is current Fiscal Year and Period so how do we filter the column to dynamically select current date in "Filter Value" section?


Solution:

Like everyone, I expected it to understand the expression. So I tried following and it worked. I used the expression


currentdate()




I was aware that I could use expression in the "Default Value" section (as explained in SAP HANA Developer Guide) but didn't expect it to

work in "Filter Value". I was able to filter the projection using this input parameter. To test the filtering, I removed the input parameter and the projection displayed all the years rather than just current year. Hopefully, when I get an explanation for this then I will share it here. For now, you can try different expressions.

10 Comments
Labels in this area