Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to get min date out of quarter

Hi,

I have a field date. by using expression month(Quartername(date))) we are getting first month of every quarter. but for that particular first month there are several dates. but i want to select the min date among those dates. how to write expression for that. so that i can get min date of that particular first month.

Regards,

Piyush

6 Replies
Not applicable
Author

and date is your dimension, or maybe you select it?

SunilChauhan
Champion II
Champion II

user quarterstart function

quarterstart(quartername(date))

hope this helps

Sunil Chauhan
tresesco
MVP
MVP

First month of the quarter; then minimum of that month, effectively is the minimum date. It seems that, you get the desired output using simply : =Min(Date)

Anonymous
Not applicable
Author

You can create a variable in the script like Min(date) and then you can call here or you can also use the Min function in your expression.

Let me know if you ned more clarification

maxgro
MVP
MVP

maybe (in a textbox, assuming y=year, d=date)

=makedate(max(y), 1 + (ceil(max(month(d))/3)-1)*3)

PradeepReddy
Specialist II
Specialist II

Try with the function Min(Date_Field).

When you selects the quarter, it returns the Min Date of that quarter.