sandele Posted September 10, 2006 Report 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!
v3rb0 Posted September 10, 2006 Report Posted September 10, 2006 count(), max() un group by - kopā saliec pac.
GedroX Posted September 11, 2006 Report Posted September 11, 2006 SELECT name, COUNT(name) as c FROM table GROUP BY name ORDER BY c DESC LIMIT 1
sandele Posted September 11, 2006 Author Report 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! :)
Recommended Posts