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

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
arulsettu
Master III
Master III

problem in set analysis

hi

     i used this set analysis

TBAL_CAL_MONTH={$(=max(TBAL_CAL_MONTH)-6)}

its giving last six month value. ex if i select 12th month its showing 6th month value. but if i select 5th month it showing blank values

it should show last year 12th month value.

why its not showing  please clarify anyone?

thanks

23 Replies
arulsettu
Master III
Master III
Author

Hi Steve,

               I used this in set analysis but still getting blank values only. am ding any mistake?

thanks

arulsettu
Master III
Master III
Author

i dont have complete date field

arulsettu
Master III
Master III
Author

Hi peter

          should i use this in set above analysis

PrashantSangle

Then Create DateField at script level.

Use MakeDate()

MakeDate(Year,Month)

Regards

Great dreamer's dreams never fulfilled, they are always transcended.
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 🙂
arulsettu
Master III
Master III
Author

Hi all

          please look at this

MakeDate(TBAL_CAL_YEAR,TBAL_CAL_MONTH) as datefield

vPrior6=date(AddMonths(datefield,-6),'MMM')

in expression

sum({<datefield={'>=$(vPrior6)'}>}TBAL_MTD_DR_LC_1-TBAL_MTD_CR_LC_1)

the result is getting current value only not previous six month value

please check it if you want sample i can do that too

thanks

arulsettu
Master III
Master III
Author

hi max,

          check below what i did if any mistake please tell me

PrashantSangle

Hi,

try like

Sum({datefield={">=$(=date(Addmonths(max(datefield),-6)))<=$(=date(max(datefield)))"}}TBAL_MTD_DR_LC_1-TBAL_MTD_CR_LC_1)

Check if i missed any brackets and also check date format of datefield and after

date(max(datefield))

Regards

Great dreamer's dreams never fulfilled, they are always transcended.
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 🙂
arulsettu
Master III
Master III
Author

here is the sample app

Not applicable

Hi Arul,

Can you share your Qlikview file with sample data so that we can try it.

Regards

Priyanka

arulsettu
Master III
Master III
Author

hi max,

               getting same current value only datefield format is M/D/YYYY