sandele Posted September 10, 2006 Report Share Posted September 10, 2006 ir tabula ar vairākiem laukiem, viena lauka dažādi ieraksti atkārtojas vairākas reizes, kā noteikt, kurš no šiem ierakstiem atkārtojas vis vairāk un izvadīt tā nosaukumu paldies! Link to comment Share on other sites More sharing options...
v3rb0 Posted September 10, 2006 Report Share Posted September 10, 2006 count(), max() un group by - kopā saliec pac. Link to comment Share on other sites More sharing options...
GedroX Posted September 11, 2006 Report Share Posted September 11, 2006 SELECT name, COUNT(name) as c FROM table GROUP BY name ORDER BY c DESC LIMIT 1 Link to comment Share on other sites More sharing options...
sandele Posted September 11, 2006 Author Report Share Posted September 11, 2006 SELECT name, COUNT(name) as c FROM table GROUP BY name ORDER BY c DESC LIMIT 1 liels paldies GedroX, tavs piemērs darbojas! :) Link to comment Share on other sites More sharing options...
Recommended Posts