Bean Machine
Member
- Local time
- Today, 07:48
- Joined
- Feb 6, 2020
- Messages
- 102
Hi All,
I am trying to count only the unique values in a specific column in my query. The field I am trying to count unique values for is the field "fld_CrNo". I have tried using SELECT DISTINCT but to no avail. There may be something more complex I need to implement in order to get it working. Any help would be greatly appreciated. The first image attached is before SELECT DISTINCT, the second is after SELECT DISTINCT, the third is my SQL, and then the fourth is what happens when I try to count them after SELECT DISTINCT. There should only be a count of 1 for "A", a count of 3 for "D" and a count of 2 for "I". Hopefully I have explained this well enough.
I am trying to count only the unique values in a specific column in my query. The field I am trying to count unique values for is the field "fld_CrNo". I have tried using SELECT DISTINCT but to no avail. There may be something more complex I need to implement in order to get it working. Any help would be greatly appreciated. The first image attached is before SELECT DISTINCT, the second is after SELECT DISTINCT, the third is my SQL, and then the fourth is what happens when I try to count them after SELECT DISTINCT. There should only be a count of 1 for "A", a count of 3 for "D" and a count of 2 for "I". Hopefully I have explained this well enough.