I would like some help writing an SQL query to export unique records from a single table, USERS. USERS is a master list of all current and previous Users of our product. There are about 75,000 records.
After excluding previous clients and inactive users, we want to generate a report that lists a count of unique Usernames and a count of unique email addresses for each of our current clients.
So, in summary, we want to create a found set of records in USERS with USERS::Status = "Client" and USERS::Restrictions = "None" From this found set, we want to create a report with three columns:
- Org ID
- Count of Unique Usernames
- Count of Unique email addresses.
Ideally, I would like to export this report to a spreadsheet.
We are using FMPA 14.01.
This seems like something better suited for an SQL query but its complexity is beyond my experience. Any help would be appreciated.