Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
munna1317
Contributor II

Set analysis problem

hi QV,s

Can you plz Tell me this Expression in Set analysis

I have CMDBCI table.

Req:I want count of CmDBCInames for current month/Count(CmdbCi Names till Previous month)

Thxs in advance

harish

22 Replies
MVP
MVP

Re: Set analysis problem

What is the format of your date field?

munna1317
Contributor II

Re: Set analysis problem

hi manish,

format of your date field:DD-MM-YYYY

MVP
MVP

Re: Set analysis problem

Have you created a Master Calendar?

Also,

What is the meaning of till Previous Month? You want starting from your first date from database to previous month end?

Count(CmdbCi Names till Previous month)

Please clarify little more on above two questions, which will make easy to answer.

munna1317
Contributor II

Re: Set analysis problem

you are Correct,I want starting from my  first date of  database to previous month end.

I have created Master calendar



MVP
MVP

Re: Set analysis problem

Can you provide sample data base or apps?

MVP
MVP

Re: Set analysis problem

For Previous Month End

=SUM({<TransactionDate = {'<=$(=MonthEnd(AddMonths(Today(),-1)))'}>}Amount)

For Current Month

=SUM({<Month = {'$(=Month(Today()))'},Year = {'$(=Year(Today()))'}>}Amount)

You can change the field names according to your application...

christian77
Valued Contributor

Re: Set analysis problem

Hi Manish

It is simpler

MonthStart(Today())-1

than

MonthEnd(AddMonths(Today(),-1))

results are the same

salutes

munna1317
Contributor II

Re: Set analysis problem

Hi Manish,

The Expression for Prevous Month is giving only Previous month Count.I need total count ( from starting date of my database )

Expression for Previous Month:

=Count({<[Fiscal Month]={'<=$(VarPrevFinMonth)'>}cmdbci_name)  it is not Working.


Regards,

Harish


Re: Set analysis problem

Hi,

Expression for previous Month End:

=Count({<[Fiscal Month]={"<=$(=VarPrevFinMonth)">}cmdbci_name)

Regards

Great dreamer's dreams never fulfilled, they are always transcended.
Community Browser