Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Sum Budget of next months of this Year!!

Hi every one ;

I create a function that calculate the Sum of Budget for the currently month :

=SUM({<[MoisBudget_Date] = {'<=$(=Today())'}, MONTHNAME_Budget = {'$(=Month(Today()))'}>}Données)

I want to create anothet indicator that calculate the sum of budget for next months of this year .

We are in March 2014, I want the sum of budget for APr, Mai., Jun , ....

What fonction shoud I create??

Thks

1 Solution

Accepted Solutions
Not applicable
Author

It works . Thank you for your help:

sum({$ <MONTHNAME={">=$(=(num(month(today()))))"}>}Données) // Next months

-SUM({<[Mois_Date] = {'<=$(=Today())'}, MONTHNAME = {'$(=Month(Today()))'}>}Données) // ( This Month )

View solution in original post

7 Replies
Gysbert_Wassenaar

For Apr: =SUM({< MONTHNAME_Budget = {'Apr'}>}Données)


talk is cheap, supply exceeds demand
MK_QSL
MVP
MVP

MONTHNAME_Budget = {'$(=Month(AddMonths(Today(),1)))'}

maxgro
MVP
MVP

I think

=sum({$ <MONTHNAME_Budget={">=$(=(num(month(today()))))"}>} Données)

If you have a calendar loaded every day and linked to your budget table, use a column flag to identify next months of this year (FlagNextMonthsThisYear) in the calendar, your expression will be much easier

=sum({$ <FlagNextMonthsThisYear={1}>} Données)

Not applicable
Author

Hi Manish;

I trying your function and it's helpful for the next Month , But I want to calculate quatity of  All Next MONTHS of the year .

Exmp:

From Apr. to December of this year .

Thnks

MK_QSL
MVP
MVP

Can you provide sample data files along with your requirements?

PrashantSangle

Hi,

try this

SUM({<[MoisBudget_Date] = {'<=YearEnd(Today())>=$(=Date(AddMonths(Today(),12)))'}>}Données)


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 🙂
Not applicable
Author

It works . Thank you for your help:

sum({$ <MONTHNAME={">=$(=(num(month(today()))))"}>}Données) // Next months

-SUM({<[Mois_Date] = {'<=$(=Today())'}, MONTHNAME = {'$(=Month(Today()))'}>}Données) // ( This Month )