>I have a parent child one to many setup
>key on an index field called locindex.
>
>Parent
>
>locindex N 6
>Station C 12
>
>
>Child
>locaindex N 6
>Qty N 6
>Price N 6
>
>I would like to know of an SQL (2.6A FoxPro Windows) Select statement that will give me all of
>the data in parent and child for only those parents with
>more than one child.
>
>Hope you all can help...TIA
Select parent.* ;
from parent,child ;
where parent.locindex=child.locindex ;
group by child.locindex ;
having count(*)>1
If you need in child data you can select into cursor and then join to child table without grouping.
Edward Pikman
Independent Consultant