Hi,

I have two tables:

<TBPersons>
IDPERSON
NAME
AGE

<TBCOURSES>
IDCOURSE
IDPERSON
TITLE
DESCRITION

Each Person have (or may have) many courses.

I want to perform a query that retrieves the total of courses for each
person, displaying also the name and age.

Can someone please help me with this?!


Many Thanks,


Jorge Oliveira
[EMAIL PROTECTED]

--------------------------------------------------------
© webfroggie.com - Recursos Online!
web: http://www.webfroggie.com
wap: http://www.webfroggie.com


------=_NextPart_000_0046_01C0ED6F.25159CA0
Content-Type: text/html;
        charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Dwindows-1252">
<META content=3D"MSHTML 5.50.4611.1300" name=3DGENERATOR></HEAD>
<BODY>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2>Hi,</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial size=3D2>I have =
two=20
tables:</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2>&lt;TBPersons&gt;</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2>IDPERSON</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2>NAME</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2>AGE</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2>&lt;TBCOURSES&gt;</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2>IDCOURSE</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2>IDPERSON</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2>TITLE</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2>DESCRITION</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial size=3D2>Each =
Person have (or=20
may have) many courses.</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial size=3D2>I want =
to perform a=20
SELECT that retrieves the total of courses for each person, displaying =
also the=20
name and age.</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial size=3D2>Can =
someone please=20
help me with this?!</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial size=3D2>Many=20
Thanks,</FONT></SPAN></DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D650042102-05062001><FONT face=3DArial=20
size=3D2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=3D650042102-05062001>
<DIV><FONT face=3DArial size=3D2>Jorge Oliveira</FONT></DIV>
<DIV><FONT face=3DArial size=3D2><A=20
href=3D"mailto:[EMAIL PROTECTED]";>[EMAIL PROTECTED]</A></FONT></DIV=
>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial=20
size=3D2>--------------------------------------------------------</FONT><=
/DIV>
<DIV><FONT face=3DArial size=3D2><FONT face=3DVerdana size=3D1>=A9 =
</FONT>webfroggie.com -=20
Recursos Online!</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>web: <A=20
href=3D"http://www.webfroggie.com/";>http://www.webfroggie.com</A></FONT><=
/DIV>
<DIV><FONT face=3DArial size=3D2>wap: <A=20
href=3D"http://www.webfroggie.com/";>http://www.webfroggie.com</A></FONT><=
/DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV><FONT face=3DArial=20
size=3D2></FONT></SPAN></DIV></BODY></HTML>

------=_NextPart_000_0046_01C0ED6F.25159CA0--



---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to