I’ve got a listbox with the following SQL:
SELECT tblLetters.ID, tblLetters.FileName, tblLetters.LetterDescription, tblLetters.LetterGroup, tblLetters.LetterDate, tblLetters.LetterLocation
FROM tblLetters
WHERE (((tblLetters.LetterGroup) Like [ClientStatus]))
ORDER BY tblLetters.LetterDate;
The possible LetterGroup fields are:
Accountant
Shareholder
Insured
Prospect
Prospect-Shareholder
ClientStatus is a combo box that holds the same values as LetterGroup, only for specific companies.
When a user is selected on a form, the listbox populates with possible letters from a table that need to be created/sent for that company. This table holds all letters, not specific letters for each type of client. The table is filtered by the LetterGroup field.
My problem is that when a ClientStatus is Prospect-Shareholder, I want to return all letters whose LetterGroup is Prospect *and* Shareholder, vice copying each letter for Prospects and Shareholders twice so that they can be included when the ClientStatus is Prospect-Shareholder.