Parents can have one or more children. I want to return the youngest child of those parents with more than one child.
I have [QryParent&children] that returns all the parents and all the children. I have used this as a sub query in [QryParents>1child].
This uses "In (SELECT [ParentsId] FROM [QryParent&children] As Tmp GROUP BY [ParentsId] HAVING Count(*)>1 )" as the criteria in the ParentId. This returns all parents with more than one child and gives the name and DOB of the child.
I now want to return just the youngest child for each parent.
An ideas?
I have [QryParent&children] that returns all the parents and all the children. I have used this as a sub query in [QryParents>1child].
This uses "In (SELECT [ParentsId] FROM [QryParent&children] As Tmp GROUP BY [ParentsId] HAVING Count(*)>1 )" as the criteria in the ParentId. This returns all parents with more than one child and gives the name and DOB of the child.
I now want to return just the youngest child for each parent.
An ideas?
Last edited: