Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I have expressions that need to be reused in many charts in my application. I would like to use a variable to do this.
The expression would look like this:
SUM({<REQUEST_CREATED_DATE={'>=$(vStartDate)'}, REQUEST_TICKET_TYPE={'Incidents'}>} TICKET_COUNT)
The problem is that the variable $(vStartDate) inside the expression is getting set to the date value (e.g. 1/1/2016) instead of the variable name. I need the text in the expression to be exactly like the above so that $(vStartDate) will change as selections are made.
I have tried the following:
SET vVariable = SUM({<REQUEST_CREATED_DATE={'>=$(vStartDate)'}, REQUEST_TICKET_TYPE={'Incidents'}>} TICKET_COUNT);
SET vVariable = "SUM({<REQUEST_CREATED_DATE={'>=$(vStartDate)'}, REQUEST_TICKET_TYPE={'Incidents'}>} TICKET_COUNT)";
The result for both is
SUM({<REQUEST_CREATED_DATE={'>=1/1/2016'}, REQUEST_TICKET_TYPE={'Incidents'}>} TICKET_COUNT)
Does anyone have a solution for this? Note that I cannot use macros.
Thanks.
Have a look at the suggested solutions here
Have a look at the suggested solutions here
Have you tried making changes to vStartDate cause I believe that the way it is structured the above expression should change with changes in vStartDate. Can you share a sample where this isn't happening?
Thanks for the replies! One of the solutions in the link worked for me. I had to use the SET the variable with a different character then replace the character in a LET solution since I had single quotes in my text. Thanks again!