Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Formula in expression in a PivotTable

How to convert text such as '2 +2' or '(20 * 5) / 100' on an outcome. But I need to do this from an expression in a PivotTable.

4 Replies
Sokkorn
Master
Master

Hi,

Try this =Replace(Field,CHR(39),'')

See the sample attached file also.

HTH and let me know.

Regards,

Sokkorn Cheav

Not applicable
Author

But in your example does not return the results

Sokkorn
Master
Master

Hi,

Try this once again

[tmp]:

LOAD * INLINE [

ID,TEST

1,''2+2''

2,''5*2''];

[Data]:

LOAD

    ID                                                        AS [ID2],

    Evaluate(Replace(TEST,CHR(39),''))        AS [TEST2]

Resident [tmp];

DROP TABLE [tmp];

Regards,

Sokkorn Cheav

Not applicable
Author

In my case, I can do the calculation in the scrip as the operand I have to be calculated based on filters set by the user on another table.