Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Invalid expression

Hi

Im trying to make this expression

Load

[journalnr],

(date - regdate)/(count(items)) as average

when i reload I get invalid expression

date - regdate gives me the number of days

count items is the number af items

so what I want is number of days divided by number of items

sorry I cant attach file

thanx

1 Reply
PhilippeMotillon
Partner - Creator
Partner - Creator

Hello,

you cannot do a count() inside the script as the script take the rows one by one.

The only way to achieve what you want to do is to create a temp table with a 'group by' to calculate that count before using the information.Hope I am clear enough.

Philippe