Hello All, > >person_tb contains mem_id, lname and fname > >details_tb contains det_id and fin.
> >They both contain other fields, but I don't care about them at this time. > > I'm trying the following > > > >select lname, fname > >from person_tb, details_tb > >where mem_id = det_id > >and fin = "y"; > > > >but it is giving me all 103 rows instead of just the ones I need. > > How is it to know which ones you need? > Add that logic to the where clause. Do you mean like: where person_tb.mem_id = details_tb.det_id and details_tb.fin = "y"; ? If so, then it gave me the whole 103 as well. > An example would be much more useful than a vague description. > Cut the data down to a smaller set and show us the problem. person_tb mem_id lname fname 001 Smith Terry 002 Jones Larry 003 Barfbag Harry details_tb det_id fin 001 y 002 n 003 y I'm trying to get Smith and Barfbag to show up instead of all three. Regards Trevor Rhodes =========================================== Powered by Linux - Mandrake 9.2 Registered Linux user # 290542 at http://counter.li.org Registered Machine #'s 186951 Mandrake Club Silver Member Source : my 100 % Microsoft-free personal computer. =========================================== 16:12:07 up 40 min, 1 user, load average: 1.23, 1.18, 1.10 -- Never mud wrestle with a pig.. you get dirty and the pig enjoys it! Never try to teach a pig to dance. You waste your time and annoy the pig. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]