Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
Qlik Analytics Tour 2020 Online. Begins August 10th. Register Today
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Not applicable

Expression to calculate revenue invoiced for today

I've written an expression to calculate revenue invoiced today using a variable but I can't seem to get the syntax correct. I keep getting error in set modifier ad hoc element list: ',' or ')' expected.

Here is my expression:

=Money(sum({<TRANDATE={$=vToday},TRANSACTION_ORDER={'0'}>}AMOUNT))

1 Solution

Accepted Solutions
Highlighted
Not applicable

Re: Expression to calculate revenue invoiced for today

I figured out the issue. My TRANDATE field did not have the same date format as my vToday variable, so I just created a new TransDate field that has the same format. Now when I plug that field into the expression you gave me it is returning a value. Thank you for your help with the expression.

View solution in original post

6 Replies
Highlighted
Specialist
Specialist

Re: Expression to calculate revenue invoiced for today

Try this:

=Money(sum({<TRANDATE={'$(vToday)'},TRANSACTION_ORDER={'0'}>}AMOUNT))

Highlighted
Partner
Partner

Re: Expression to calculate revenue invoiced for today

Hi,

have you tried

=Money(sum({<TRANDATE={$(=vToday)},TRANSACTION_ORDER={'0'}>}AMOUNT))

Highlighted
MVP
MVP

Re: Expression to calculate revenue invoiced for today

=sum {$ <TRANDATE={$(vToday)},TRANSACTION_ORDER={0}>}AMOUNT)

Highlighted
Not applicable

Re: Expression to calculate revenue invoiced for today

This expression is at least not returning an error, but the amount I am getting is 0. It should be around 100K, so I need to figure out what I am still doing wrong.

Highlighted
Specialist
Specialist

Re: Expression to calculate revenue invoiced for today

Can you post a sample?

Highlighted
Not applicable

Re: Expression to calculate revenue invoiced for today

I figured out the issue. My TRANDATE field did not have the same date format as my vToday variable, so I just created a new TransDate field that has the same format. Now when I plug that field into the expression you gave me it is returning a value. Thank you for your help with the expression.

View solution in original post