- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
how to get min date when a fiscal year or fiscal year pluse quarter is selected
Hello All,
From the above sample data for a particular material ,when either a fiscal year(2017) or fiscal year pulse quarter one(Q1) is selected i need to bring PRICE_MAT =1.75(VALIDFROM=4/2/2016) and
If Fiscal year and Quarter Three(Q3) is selected then i need to bring PRICE_MAT=1.8 which is having max VALIDTO(12/31/9999) for that particular material ...
How to write a expression to achieve the above requirement ,any suggestions please
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Try
Sum({ <VALIDFROM = {"$(=Max(VALIDFROM))"}>}PRICE_MAT)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for your reply ,but the above expression wont full fill my requirement ...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
How do you calculate fiscal_year and Qurter??
Try below
Sum({ <VALIDFROM = {"$(=Min(VALIDFROM))"},VALIDTO = {"$(=Max(VALIDTO ))"}>}PRICE_MAT)
regards,
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
HI,Fiscal year i am getting from data source itself ,for quarter i wrote this
If(Right(CALMONTH,2)>=04 and Right(CALMONTH,2)<=06,'Q1',
If(Right(CALMONTH,2)>=07 and Right(CALMONTH,2)<=09,'Q2',
If(Right(CALMONTH,2)>=10 and Right(CALMONTH,2)<=12,'Q3','Q4'))) as QUARTER,