Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello, assuming I have the following table
Computer_ID | Date_Used | On_State |
---|---|---|
1 | 1.01.2017 | 1 |
2 | 1.01.2017 | 1 |
3 | 1.01.2017 | 1 |
1 | 1.01.2017 | 1 |
2 | 1.01.2017 | 1 |
1 | 1.01.2017 | 1 |
3 | 3.01.2017 | 1 |
how can I sum all the days all the computers have been used on "On_State" = 1 without adding the duplicates? Is there any way to use DISTINCT in Sum's Set Expression?
I'm looking for the following output for the said expression(in a PivotTable), given the table above:
Computer_ID | Days_used |
---|---|
1 | 1 |
2 | 1 |
3 | 2 |
May be this
Count(DISTINCT Date_Used)
Thanks, it works!