Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
pyrodirk
Contributor
Contributor

Evaluate functions from a inline table

Hi,

i want to create an inline table with two fields. First one is a descriptive text, the second one is a kind of function like this:

Dateninsel_Formeln:

LOAD * INLINE [

    Formeltext, Formel

    COUNT_CUSTMERS, =count(CUST_NR)

    SUM_TURNOVER, sum( PRICE * QUANTITY)

   

];

Is it possible to create a table or chart of this table so that the expressions are evaluated/calculated in the object ?

Regards

Dirk

1 Solution

Accepted Solutions
swuehl
MVP
MVP

I think the only way to achieve this is a pick/match combination, like:

=pick(

match(Formeltext,$(=chr(39)&concat(Formeltext, chr(39)&','&chr(39),FormelID)&chr(39))),

$(=concat(Formel,',',FormelID))

)

There has been a quite similar thread posted today, almost at the same time, so you might also check this.

edit: http://community.qlik.com/message/246255#246255

Regards,

Stefan

View solution in original post

3 Replies
a_mullick
Creator III
Creator III

Hi Dirk,

I had a look at this and only got a partial solution, but it may inspire you...

In the simple table I have made (Formula Headings and Expressions), the solution fails if you try and add the turnover formula to the table. To me it kind of makes sense that you can't dynamically alter an expression.

If it is just your intention to just have re-usable expressions, then you can achive this by just defining variables in the document and using them when needed. See the attached qvw for the examples.

Regards,

Azam

IAMDV
Luminary Alumni
Luminary Alumni

Dirk,

Please see the attachment but you need to make a selection to perform the calculation. I hope this makes sense.

Good luck!

Cheers,

DV

www.QlikShare.com

swuehl
MVP
MVP

I think the only way to achieve this is a pick/match combination, like:

=pick(

match(Formeltext,$(=chr(39)&concat(Formeltext, chr(39)&','&chr(39),FormelID)&chr(39))),

$(=concat(Formel,',',FormelID))

)

There has been a quite similar thread posted today, almost at the same time, so you might also check this.

edit: http://community.qlik.com/message/246255#246255

Regards,

Stefan