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

Count Of employees greater than limit time

Dear All,

I need to display count of emp greater than IN time entry. vSignin as IN time variable. Any one can help me to this set expression syntax.

Following is the expression I'm using where it is not showing any error in expression view but no data returned.

=count({<tran_date={'$(=maxstring(tran_date))'},SignIn={">$(vSignin)"}>}distinct EmpName)

19 Replies
kakani87
Specialist
Specialist
Author

here in sample data considered SignIn and SignOut as field value but actually Min IN time and Max OUT are considered

so not able to achieve in the dashboard I'm doing.

Actually your expression returns the exact in sample file now where I'm going wrong here in Dashboard Tresesco.




Emp_Entries.png


tresesco
MVP
MVP

Sorry, I could not follow. Are you saying that it (my exp) works in sample app and not in actual app?

kakani87
Specialist
Specialist
Author

Yes

tresesco
MVP
MVP

Then? Try to resolve yourself, or, let us know what else aspects make your actual app different from the sample one, so that we can predict some possible reasons, or let us check your app that demonstrates the issue.

kakani87
Specialist
Specialist
Author

App With Possible Data I'm Sharing you.

tresesco
MVP
MVP

In this app, your SignIn format is different ('hh:mm:ss TT'), and so has to be incorporated in your expression like:

=Count({<SignIn={">$(=time(vSignin,'hh:mm:ss TT'))"},tran_date={'$(=maxstring(tran_date))'}>}DISTINCT EmpName)

kakani87
Specialist
Specialist
Author

Tresesco .. this expression Returns the opposite value Could you kindly suggest me to do the required changes to achieve exact output. Like Count suppose to be '2' when greater than time as  highlited in the below screen it is showing like count of '8'

Delay_Entries.png

kakani87
Specialist
Specialist
Author

In the earlier sample shared by you it is showing Proper data

Reference purpose

PFA.

Correct Sample.png

tresesco
MVP
MVP

I guess you are trying to count the employees with RED highlighted condition satisfied, if so, try:

=Count({<EmpName={"=Min({<tran_date = {$(=Num(Max(tran_date)))}>} SignIn)>$(vSignin)"},tran_date={'$(=maxstring(tran_date))'}>}DISTINCT EmpName)

kakani87
Specialist
Specialist
Author

Thank you for your time Tresesco.

This gives Correct Count