BrunoDelFrate
Programmer
Hello,
I'm using a piece of code like this one, with SQL Server 7.0:
It works... BUT it also updates some other records OUTSIDE the ones in the recordset, apparently at random!
But if I change the first line into this:
...it works perfectly!
Why???????
I've also tried to put a response.write rs("rownumber" before updating, and it looks like it finds the right records... is it a known bug? My table has no indexes and no keys - I cannot put keys because in some cases I need to have duplicates and to change key fields.
Thanks in advance!
Bruno Del Frate
I'm using a piece of code like this one, with SQL Server 7.0:
Code:
<%
query = "SELECT rownumber FROM database WHERE ordernumber = 'XXX'"
rs.open query
do until rs.eof
rs("rownumber") = newvalue
rs.update
rs.movenext
loop
%>
But if I change the first line into this:
Code:
<% query = "SELECT ordernumber, rownumber FROM database WHERE ordernumber=... %>
Why???????
I've also tried to put a response.write rs("rownumber" before updating, and it looks like it finds the right records... is it a known bug? My table has no indexes and no keys - I cannot put keys because in some cases I need to have duplicates and to change key fields.
Thanks in advance!
Bruno Del Frate