I have a select query which is using the distinctrow predicate to return
parent rows who's child rows meet the set criteria.
for example:
SELECT DISTINCTROW Clients.Client
FROM Clients LEFT JOIN Contacts ON Clients.ID = Contacts.[Record ID]
WHERE ((Contacts.Date)<#8/20/2006#);
The problem i'm having is, if there are 2 child rows, and one matches the
criteria, and the other doesn't, it will still return the parent row. Is
there a way to only return the parent row if all child rows match the
criteria? And still be able to edit the data via the query?
Re: Query returning unwanted results ... introduce are eliminated by the WHERE clause.... The problem i'm having is, if there are 2 child rows, and one matches the ...criteria, and the other doesn't, it will still return the parent row.... (microsoft.public.access.queries)
Re: Queries involving subforms ... I don't want the query to return any child rows, only parent rows, but based ... indicate a particular parent row.... is there anyway to base the criteria for a query ... (microsoft.public.access.queries)
Re: Accept/Reject Cascading - DataSet ... can still first delete the child rows and then the parent row.... When AcceptRejectRule is set the Cascade,... (microsoft.public.dotnet.framework.adonet)
Re: Queries involving subforms ... If you create your query, with the parent & child tables joined, and add ... you will get as many as there are child rows... combination of parent row values only once. ... I have a main form with 1 subform, I want to make a query that ... (microsoft.public.access.queries)
Re: setting foreign key to null when deleting primary key ... If child rows exist with the foreign key value of the parent then a delete ... of the parent row will fail unless you have the ON DELETE CASCADE option ... (microsoft.public.sqlserver.programming)