Bhavin, I am using distinct all 15 fields and order by all 15 fields, but there is different order on 15 fields for distinct and order by.
Thanks At 08:24 PM 7/10/2002 -0700, Bhavin Vyas wrote: >Via mysql, you are trying to do a distinct 'field1'. So any field1 >duplicates will be removed. Where as in the Linux sort only entire row >duplicates will be removed meaning 'field1 field2'. They would return the >same number of records only if you selected field1 only and then sorted it >via the Linux sort. > >Regards, >Bhavin. >----- Original Message ----- >From: "Vivian Wang" <[EMAIL PROTECTED]> >To: <[EMAIL PROTECTED]> >Sent: Wednesday, July 10, 2002 11:00 AM >Subject: Question about group by or distinct > > > > Hi, > > > > I have a 76,500,000 rows table with 15 fields. > > I try to sort this rows on all fields, so I am using select all fields1 > > group by all fields2 or distinct all fields1 with order by all fields2. > > After sort, I get 62,000,000 rows. > > > > Then I use Linux unique sort, I dump out 76,500,000 table and using >sort -u > > file1 -o file2. > > I got 76,000,000 rows. > > > > I don't know what is wrong about mysql's group by or distinct. > > Are there any restricts on group by or distinct like number of fields, or > > size of table or rows of table? > > > > Any help is appreciated. > > > > > > --------------------------------------------------------------------- > > 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 > > --------------------------------------------------------------------- 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