Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Why is this an invalid expression?


Hi, I'm just getting into QlikView and trying to learn.....  I cannot see the error in the following expression, even thought I know it must be simple.    Suggestions?     Thanks,        Tee

LOAD count(SURGEON) as cases,
     FACILITY_NAME,
     Year,
     Month
From
D:\Documents\QlikView\t_SampleData.xlsx
(ooxml, embedded labels)
where FACILITY_NAME like '*South' and Year = '2011'
Group by  SURGEON,Month;

1 Solution

Accepted Solutions
danielrozental
Master II
Master II

Try

Group by  FACILITY_NAME, Year, Month;

View solution in original post

4 Replies
danielrozental
Master II
Master II

Try

Group by  FACILITY_NAME, Year, Month;
its_anandrjs

Hi,

You have to write

LOAD count(SURGEON) as cases,

     FACILITY_NAME,

     Year,

     Month

From

t_SampleData.xlsx

(ooxml, embedded labels, table is Sheet1)

where FACILITY_NAME = 'South' and Year = 2011

Group by  FACILITY_NAME, Year, Month;

Rgds

Anand

Not applicable
Author

Thanks,  that suggestion worked..  Now I'm wondering why?

Not applicable
Author

hi,

You cannot group by over a field you use in an expression. That's normal, because you want to count or sum this field. You always have to group by over all the other fields.

More details you find in the manuel help under the capitel "script".

Regards

vicky