Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Create Bar chart for intervals of dates

Hi all,

I have doubt in creating intervals of single date field. I have one date field called OrderDate. I want to create bar chart, in that chart every bar displays 15 days of sales. How can i get this? What dimension i use for this?. I want create chart like below.

Thanks in advance.

Picture1.png

7 Replies
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

See this blog post: Recipe for a Histogram


talk is cheap, supply exceeds demand
deepakqlikview_123
Specialist
Specialist

Can u plz try class or interval function

Class Function Example

Thanks,

Deepak

Kushal_Chawda

Create the chart like below.

Dimension:

=class(OrderDate, $(vOffset))

Expression:

=Sum(Sales)

vOffset variable can be set on Button trigger.


for Button "15 Days"

Go to Button Properties->Action-> External-> Set variable

Variable = vOffset

Value =15


Like wise you can set the variable with different value for 30 days, 45 days


So when you click on 30 days button value will be set and the chart dimension will pick the offset inside class function.

Not applicable
Author

Thanks kushal.

Its working. But how can i set dimension labels like  10/13/2011 to 10/28/2011.

Any suggestion.

Thanks in advance.

deepakqlikview_123
Specialist
Specialist

try class function

Not applicable
Author

Hey Kushal,

how would I create a button?