I have two tables, related. I have two listboxes. The first listbox I want to list primary records that have cild records existing in the second related table.
In other words, Listbox 1 will show Company A, with it's primary key, and the second listbox will show related records to the selected company A.
My listbox rowsource for list 1 is:
SELECT DISTINCT PARTNERS.ID1, PARTNERS.Partner, ACTIVITIES.[Task Description]
FROM PARTNERS INNER JOIN ACTIVITIES ON PARTNERS.ID1 = ACTIVITIES.ID1
WHERE (((ACTIVITIES.[Task Description])>""))
ORDER BY PARTNERS.Partner;
However it shows the company (Partner) as many times in list 1 as there are records in list 2, instead of just once.
Hope thats not confusing. So eg Lisbox 1 shows one company, Listbox 2 shows 6 related records to that company.
Many thanks
In other words, Listbox 1 will show Company A, with it's primary key, and the second listbox will show related records to the selected company A.
My listbox rowsource for list 1 is:
SELECT DISTINCT PARTNERS.ID1, PARTNERS.Partner, ACTIVITIES.[Task Description]
FROM PARTNERS INNER JOIN ACTIVITIES ON PARTNERS.ID1 = ACTIVITIES.ID1
WHERE (((ACTIVITIES.[Task Description])>""))
ORDER BY PARTNERS.Partner;
However it shows the company (Partner) as many times in list 1 as there are records in list 2, instead of just once.
Hope thats not confusing. So eg Lisbox 1 shows one company, Listbox 2 shows 6 related records to that company.
Many thanks