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

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Expression error?

Hi,

I have dimension and expression as below in straight table

Dimension: TeamMember

Expression: Count(DISTINCT {$<Source={'ITDepartment'},Order={ITDepartment'},Result={'Work Completed'},Flag={1}>}EmployeeID)

when I select the Date from 03/03/2014 to 07/03/2014 the count of the expression is showing 10 whereas in the database the count is showing 5. can anynone please tell me is there anything wrong in expression?

Thanks.

38 Replies
Not applicable
Author

Please find attached and help me. This is my original file

MK_QSL
MVP
MVP

Please add your original  drft table also as Date field is still wrong..

manojkulkarni
Partner - Specialist II
Partner - Specialist II

In the attached application I don't see value 10 as mentioned above. It is showing 5.

Not applicable
Author

Please find attached.

MK_QSL
MVP
MVP

Dear Amelia,

Your Date and When field is actually a timestamp.

You need to convert them in Date as below..

TblPast:

LOAD '1' as Flag,

     PastID,

     EmployeeID,

     Order,

     Source,

     Date(Floor(When)) as When,

     TeamMember,

     Result

FROM

drft.xlsx

(ooxml, embedded labels, table is Sheet2);

TblWork:

LOAD '2' as Flag,

     EmployeeID,

     Date(Floor(Date)) as Date,

     Order

FROM

drft.xlsx

(ooxml, embedded labels, table is Sheet1);

Now you can try after reloading your apps.

Not applicable
Author

Thanks. I tried as you said but still showing the same. Is there anything I need to change?

MK_QSL
MVP
MVP

please check enclosed file...

Not applicable
Author

Thanks and still it is showing the same result. I am not getting the differences in the data. Is there any way to fix this please?

MK_QSL
MVP
MVP

You want result 5 and it is in the file I have attached.

If you think you are getting 10 then definitely the file you have given as a sample and the file you are actually using are different with different data set.

Let me know if I am wrong.

Not applicable
Author

Thanks. that's how I have the data in the table. moreover if I made partial sums it is showing

8+2+2+0=10

it's really strange. I totally confused here the sum of the values also showing different.