sto estraendo i dati da una tabella, cercando di incolonnarli in base al tipo di dato estratto.
Esempio
Gruppo tipo A tipo B
XXXX se tipo=A allora valore CCCC se tipo = B allora valore DDDDD
ottengo invece
Gruppo tipo A tipo B
XXXX se tipo=A allora valore CCCC
XXXX se tipo = B allora valore DDDDD
in altri termini l'unica riga viene divisa in più righe, una per ciascuna tipologia estratta.
questo è il codice:
codice:
<table border="1" cellspacing="1" style="border-collapse: collapse" bordercolor="#111111" width="86%" height="41">
</p>
<td width="26%" align="center" height="19" bgcolor="#FFFF00">
<font face="Verdana" size="4">gruppo</font></td>
<td width="5%" align="center" height="19" bgcolor="#FFFF00">
<font face="Verdana" size="4">c</font></td>
<td width="5%" align="center" height="19" bgcolor="#FFFF00">
<font face="Verdana" size="4">g</font></td>
<td width="4%" align="center" height="19" bgcolor="#FFFF00">
<font face="Verdana" size="4">s</font></td>
<td width="4%" align="center" height="19" bgcolor="#FFFF00">
<font face="Verdana" size="4">l</font></td>
<td width="4%" align="center" height="19" bgcolor="#FFFF00">
<font face="Verdana" size="4">e</font></td>
<td width="2%" align="center" height="19" bgcolor="#FFFF00">
<font face="Verdana" size="4">r</font></td>
<td width="3%" align="center" height="19" bgcolor="#FFFF00">
<font face="Verdana" size="4">rs</font></td>
<td width="21%" align="center" height="19" bgcolor="#FFFF00">
<font face="Verdana" size="4">Nome</font></td>
</tr>
<%
Do While Not RS.EOF
conteggio=RS("conteggio")
%>
<tr>
<td width="26%" align="center" height="15" bgcolor="#DDDDDD"><font face="Verdana" size="4"><%=RS("gruppo")%></a></font></td>
<td width="5%" align="center" height="15" bgcolor="#DDDDDD"><font face="Verdana" size="4"><%if RS("tipo unita'")="C" then response.write(conteggio)%></a></font></td>
<td width="5%" align="center" height="15" bgcolor="#DDDDDD"><font face="Verdana" size="4"><%if RS("tipo unita'")="G" then response.write(conteggio)%></a></font></td>
<td width="4%" align="center" height="15" bgcolor="#DDDDDD"><font face="Verdana" size="4"><%if RS("tipo unita'")="S" then response.write(conteggio)%></a></font></td>
<td width="4%" align="center" height="15" bgcolor="#DDDDDD"><font face="Verdana" size="4"><%if RS("tipo unita'")="L" then response.write(conteggio)%></a></font></td>
<td width="4%" align="center" height="15" bgcolor="#DDDDDD"><font face="Verdana" size="4"><%if RS("tipo unita'")="E" then response.write(conteggio)%></a></font></td>
<td width="2%" align="center" height="15" bgcolor="#DDDDDD"><font face="Verdana" size="4"><%if RS("tipo unita'")="R" then response.write(conteggio)%></a></font></td>
<td width="3%" align="center" height="15" bgcolor="#DDDDDD"><font face="Verdana" size="4"><%if RS("tipo unita'")="RS" then response.write(conteggio)%></a></font></td>
</tr>
<%
RS.MoveNext
Loop
%>
</table>
dove sbaglio? mi sembra di aver rispettato i tag TD /TD e TR /TR