<% dim mytable,mytotal, notes Set Rs1= Server.CreateObject("ADODB.Recordset") if mysqldatechar="'" then Rs1.CursorLocation = 3 end if StrSQL="SELECT * from stanze ORDER BY ordine" Rs1.Open StrSQL,mydbstring,1,2,1 if not Rs1.eof then mytotal=Rs1.recordcount Do While Not rs1.EOF If (rs1("prezzo") = 0) Then non_disponibile = "NOT AVAILABLE" Else non_disponibile = "" End If mytable=mytable &" " & rs1("nome")& " " & non_disponibile & "" if isnumeric(rs1("prezzo")) then mytable=mytable &" " If rs1("prezzo") > 0 Then mytable = mytable & formatnumber(rs1("prezzo"),2,0,0,-2) & " €" End If mytable = mytable & "  " else mytable=mytable &" " end if mytable=mytable & "" ' elenco eventuali prezzi temporanei sotto alla riga relativa alla singola stanza con il prezzo di default sql="SELECT * from prezzo_temporaneo where stanza = " & rs1("id") & " and al >= #" & isoDate(Now()) & "# ORDER BY dal;" 'response.write sql 'response.end Set rs= Server.CreateObject("ADODB.Recordset") rs.Open sql,mydbstring,1,2,1 If Not rs.EOF Then Do While Not rs.EOF dal = Day(rs("dal")) & "/" & Month(rs("dal")) & "/" & Year(rs("dal")) al = Day(rs("al")) & "/" & Month(rs("al")) & "/" & Year(rs("al")) If (rs("prezzo") = 0) Then non_disponibile = "NOT AVAILABLE" Else non_disponibile = "" End If mytable=mytable &" Dal " & dal & " al " & al & "  " & non_disponibile & "" mytable=mytable &" " If rs("prezzo") > 0 Then mytable = mytable & formatnumber(rs("prezzo"),2,0,0,-2) & " €" End If mytable = mytable & " " mytable=mytable & "" rs.movenext Loop End If rs.close mytable=mytable &"" Rs1.movenext loop end if Rs1.close set rs1=Nothing %> <%=mytable%>