Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Count Children in SQL Select
Message
General information
Forum:
Visual FoxPro
Category:
FoxPro 2.x
Miscellaneous
Thread ID:
00015517
Message ID:
00015582
Views:
34
>
>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.

I do need child data and parent data, what I want is an
SQL select statement that will out put for only those
parents that have more than one child, and I want to see data for
both parent and child.

Thanks for your help thus far...I would like to get it down to
one select statement.
Bret Hobbs

"We'd have been called juvenile delinquents only our neighborhood couldn't afford a sociologist." Bob Hope
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform