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

Announcements
Qlik Connect 2026 Agenda Now Available: Explore Sessions
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Bar Chart Dimension Issue

Hello,

I am a beginner on QlikView, and i would to create a chart which shows the result of the 12 last "MaJ" from the "Maj" Selected (1 year period from the Maj selected) :

Capture.PNG

However my chart shows just the result of the MaJ selected:

Capture.PNG

(Here "STEASoF" = "MaJ")

The dimension:

Capture.PNG

And the Expression looks like:

Capture.PNG

Do you have an idea ?

Thanks for advance for your help,

Cocalero.

1 Solution

Accepted Solutions
swuehl
MVP
MVP

swuehl wrote:

Well, you can create another field in your script that just enumerates the field values in chronological order.

Then use the set modifier on that field (and clear selections on the other calendar field).

But I think your issue in above sample is that your upper limit is still formatted as date, use the num() function also on the upper limit.

=SUM({$<Job_Titles = {'Trader'}, STEAsOf = {">=$(=Num(AddMonths(Max(STEAsOf),-12)))<=$(=Num(Max(STEAsOf)))"}>} STE)


Just in case my previous answer got lost...

View solution in original post

35 Replies
Chanty4u
MVP
MVP

can u explain more?

what is expected output?

swuehl
MVP
MVP

Maybe like

Sum({$<Job = {'Trader'}, STEAsOf = {">=$(=Num(AddMonths(MaJ,-12)))"}, MaJ= >} STE)

sunny_talwar

What format does you STEASoF comes in? Date or number?

If it is number, then try this:

Sum({<Job = {'Trader'}, STEASoF = {"$(='>=' & (Max(STEASoF) - 12) & '<=' & Max(STEASoF))"}>} STE)

If it is date format, then try this:

Sum({<Job = {'Trader'}, STEASoF = {"$(='>=' & Date(Max(STEASoF) - 12), 'DateFieldFormatHere') & '<=' & Date(Max(STEASoF), 'DateFieldFormatHere'))"}>} STE)

Anonymous
Not applicable
Author

Hello,

Thanks for your help but it doesn't work 😕

I tried this Expression:

Capture.PNG

My STEAsOF looks like that:

Capture.PNG

I would like to have the results of the 12 last STEAsOf from my STEAsOf Selected on my Chart:

Capture.PNG

Cocalero.

swuehl
MVP
MVP

Could you post a small sample QVW?

Anonymous
Not applicable
Author

I am so sorry but i can't 😕

But i can post some Screenshots

sunny_talwar

few sample rows of data? not even real data, may be some made up dummy data

swuehl
MVP
MVP

Why not?

Anyway, have you tried my suggested expression?

Your STEAsOf values are essentially Month end dates, so you should use AddMonths() function or AddYears() to return a date 12 months back.

And you might also need to clear other user selections in calendar fields to prevent an incompatible set. Just as I did with MaJ field.

Anonymous
Not applicable
Author

Here a QlikView test where there is a chart staked, with 3 different AsOF.

I would like to show 2 AsOf into the dimension: the AsOf Selected and the previous one.

Thanks for advance,

Cocalero.