ABSOLUT FEMENÍ

SELECT nom as sujeto, dni as doc, sexe as sex1, categoria as cate, IFNULL((SELECT puntsgen FROM historic WHERE idcursa=130 AND dni=doc ),0) AS una, IFNULL((SELECT puntsgen FROM historic WHERE idcursa=131 AND dni=doc ),0) AS dos, IFNULL((SELECT puntsgen FROM historic WHERE idcursa=132 AND dni=doc ),0) AS tres, IFNULL((SELECT puntsgen FROM historic WHERE idcursa=133 AND dni=doc ),0) AS quatre, IFNULL((SELECT puntsgen FROM historic WHERE idcursa=134 AND dni=doc ),0) AS cinc, IFNULL((SELECT puntsgen FROM historic WHERE idcursa=135 AND dni=doc ),0) AS sis, IFNULL((SELECT puntsgen FROM historic WHERE idcursa=136 AND dni=doc ),0) AS siet, IFNULL((SELECT puntsgen FROM historic WHERE idcursa=137 AND dni=doc ),0) AS vuit, IFNULL((SELECT puntsgen FROM historic WHERE idcursa=138 AND dni=doc ),0) AS nou, IFNULL((SELECT puntsgen FROM historic WHERE idcursa=139 AND dni=doc ),0) AS deu, IFNULL((SELECT puntsgen FROM historic WHERE idcursa=140 AND dni=doc ),0) AS once, SUM(puntsgen) AS punts, SUM(empat) as desempat FROM historic WHERE sexe="F" GROUP BY dni ORDER BY punts DESC, desempat ASC..
Pos Nom Cat. AmpostaL'AmpollaUlldeconaPerellóS.BàrbaraCamarlesTortosaJesúsDeltebreLa GaleraL'Aldea Total Punts
1 MARQUEZ GARCIA, SILVIA VE1 F1150000000000 115 115
2 DRAGO ROSA, HELENA SEN F1030000000000 103 103
3 ALSO ROIGET, TERE VE1 F930000000000 93 93
4 BATALLA DOMINGUEZ, SITA VE2 F850000000000 85 85
5 SANCHO FERRÉ, ANDREA SEN F790000000000 79 79
6 FORT RODRIGUEZ, ROSANA VE1 F750000000000 75 75
7 PELLICER MARTINEZ, SANDRA VE1 F730000000000 73 73
8 GISBERT TORTA, VERÒNICA VE2 F710000000000 71 71
9 ESCUDERO BARBERÀ, CINTA SEN F700000000000 70 70
10 COMES I FORASTERO, PILI VE1 F690000000000 69 69
11 ESTORACH ARASA, MIRIAM VE1 F680000000000 68 68
12 TORTA, CARME VE1 F670000000000 67 67
13 SANCHEZ HURTADO, CARMEN VE2 F660000000000 66 66
14 PARRAMON SOLER, GEMMA VE2 F650000000000 65 65
15 FALCÓN TORMO, EVA VE1 F640000000000 64 64
16 JORNET SABATÉ, MIRIAM SEN F630000000000 63 63
17 FORÉS ESTRADA, IMMA MA1 F620000000000 62 62
18 CABALLÉ FABRA, RAQUEL VE1 F610000000000 61 61
19 BERMEJO MULET, MONTSE VE2 F600000000000 60 60
20 SEGURA RIUS, ELENA VE2 F590000000000 59 59
21 RUIZ MARTINEZ, VANESSA VE1 F580000000000 58 58
22 BROUGHTON, BETTINA MA1 F570000000000 57 57
23 IRIGOYEN GARCIA, SILVIA VE1 F560000000000 56 56
24 ALMEIDA JIMENEZ, MONICA VE2 F550000000000 55 55
25 IBAÑEZ ARTIGAS, TRINI VE1 F540000000000 54 54
26 MARTÍNEZ ESQUERRÉ, MARIA TERESA VE2 F530000000000 53 53
27 LARA, CLARISA VE1 F520000000000 52 52
28 COMÍ CODINA , SÒNIA VE1 F510000000000 51 51