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

Group by

I think this is a simple task but not sure why it's not working.

I want to group by a field (employees' location) and count the number of employees per location, and have them in a separate table.

TempTable:

Load

     [employees location],

     Count([Employee ID]) as [Number of employees at Location]

Group by

     [employees location];

When I load the script, my TempTable is not showing up anywhere, neither the [Number of employees at Location] field. Not sure what's happening?

1 Solution

Accepted Solutions
sunny_talwar

You might have missed the Resident tablename;

TempTable:

Load

    [employees location],

    Count([Employee ID]) as [Number of employees at Location]

Resident TableName

Group by

    [employees location];

View solution in original post

4 Replies
sunny_talwar

You might have missed the Resident tablename;

TempTable:

Load

    [employees location],

    Count([Employee ID]) as [Number of employees at Location]

Resident TableName

Group by

    [employees location];

Not applicable
Author

Thanks:) So I added resident Table, but now it says "Table not found TempTable: ...."

sunny_talwar

Can you share the complete script you are using?

Anonymous
Not applicable
Author

Hi QlikNewbie,

Are you calculating this table on Section Access?

If the answwer is yes, calculate it on Section Application.

If the answer is no, try

TempTable:

Load

     [employees location],

     Count(Distinct [Employee ID]) as [Count of Number of employees at Location]

Resident YourTable

Group by

     [employees location];