Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
i want to achieve in the dashboad on open trigger
by default current quarter and next 3 quarters [means 4quarters should be selected]
i have quarter field
2017Q1
2017Q2
..
2018Q4
2019Q1
2019Q2
2019Q3
2019Q4
for example current quarter is 2018Q4 so my requirment is to be default selction 2018Q4,2019Q1,2019Q2,2019Q3
it should be dynamic ....if i will be in 2019Q1 ...it will treat as 2019Q1 as current like that
thanks
Sony
Hi,
Here is the solution.
Script:
Let vMin = num(MakeDate(2017,01,01));
Let vMax = num(MakeDate(2018,08,01));
Temp:
Load Date($(vMin) + RowNo() -1) as Date
AutoGenerate 1
While Date($(vMin) + RowNo() -1) < Date($(vMax));
Master:
Load Date,
Year(Date) & 'Q'&Ceil(NUm(Month(Date))/3) as YearQtr,
QuarterStart(Date) as QtrStart
Resident Temp;
Drop table Temp;
Trigger Expression:
='('&Concat({<Date = {">$(=Max(QtrStart,4))"}>}distinct YearQtr,'|')&')'
Also QVW is attached.
Regards,
Kaushik Solanki !
Hi Sony,
I attach a solution, creating variables in load script and creating an ID for every quarter.
I inserted the script as onOpen trigger and in the button.
Let me know.
Simone
thanks alot.. i will test from my side also
Hi Sir,
in this variables you are static values are giving ?
Script:
Let vMin = num(MakeDate(2017,01,01));
Let vMax = num(MakeDate(2018,08,01)); ----this value
every time i need to change current month?
Hi,
This is just for testing, you can change vMax to Today().
So everytime it will get updated with today's date.
Regards,
Kaushik Solanki
thanks for the info.i will check it
one more doubt
if i dont want to use master calendar here
i have only fisxal quarter values coming as 2017Q1 2017Q2....2018Q3,2018Q4,2019Q1 like so one.. i dnt have date field in my data directly user is providing the fiscal quarter field.
so how can i achieve this?
Hi,
You need to get the Date field, so that it max(4th Last Max Value) can be found.
You wont be able to get the Max(4th Last Max Value) from string.
Regards,
Kaushik Solanki