Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

segerchr
New Contributor II

Set analysis Today()

Post edited by Community Team member:

Please only post in English unless in a dedicated language section.

Translation done by Google translate.

---

Hi,

I'm trying a helpdesk solution by Set Analysis structuring.

Have the following line input:

acTicketErstelldatum is in the data model as: illustrated 41235.46. That is my opinion ok.

Target: All tickets which were created today.

Sum({$<acTicketErstellungsdatum={'date(today()'}>}[#ITTicket_erstellt_Zähler])

Can you help me here in troubleshooting?

Greeting

CS

1 Solution

Accepted Solutions

Re: Set analysis Today()

May be this:

Sum({$<acTicketErstellungsdatum={"=Num(Floor(acTicketErstellungsdatum)) = Num(Today())"}>}[#ITTicket_erstellt_Zähler])

7 Replies

Re: Set analysis Today()

Sum({$<acTicketErstellungsdatum={'$(=Date(Today()))'}>}[#ITTicket_erstellt_Zähler])

Re: Set analysis Today()

May be this:

Sum({$<acTicketErstellungsdatum={"=Num(Floor(acTicketErstellungsdatum)) = Num(Today())"}>}[#ITTicket_erstellt_Zähler])

MVP
MVP

Re: Set analysis Today()

Sum({$<acTicketErstellungsdatum={'$(=date(today())'}>}[#ITTicket_erstellt_Zähler])


But your field acTicketErstellungsdatum seems to be a timestamp in fact, so either create a pure date field in the script or try

Sum({$<acTicketErstellungsdatum={">=$(=num(Daystart(today()))<=$(=num(Dayend(today()))"}>}[#ITTicket_erstellt_Zähler])


segerchr
New Contributor II

Re: Set analysis Today()

Hi,

thanks for your answers. But it doesnt work.

Sum({$<date(acTicketErstellungsdatum)={'$(=Date(Today(),'DD-MM-YYYY'))'}>}[#ITTicket_erstellt_Zähler])

The function date(acTicket... compare with the function Date(Today(),'DD-MM-YYYY' has the similar result.

Re: Set analysis Today()

This isn't going to work this way. You cannot have Functions (Date()) on the left hand side of the set analysis modifier.

segerchr
New Contributor II

Re: Set analysis Today()

OK thanks for your answer.

Now i have vToday as a variable declarated, but the code still doesn`t work.

Count({$<acTicketErstellungsdatum={'vToday'}>}[#ITTicket_erstellt_Zähler])

Can you find a another solution ?

Thanks

segerchr
New Contributor II

Re: Set analysis Today()

count({$<acTicketErstellungsdatum={"=Num(Floor(acTicketErstellungsdatum)) = Num(Today())"}>}acTicketnr)

This was the correkt code. Thanks your answer was right.

Community Browser