SQL Update problem
Posted in 1999
I enter the following statements on an NT server running IDS 7.3.TC5:
select count(*) from myTable
where col1 < 46000
and col1 in (select col1 from myOtherTable);
update myTable
set col2 = "N"
where col1 < 46000
and col1 in (select col1 from myOtherTable);
The first statement returns a count of 2000.
The second statement updates 2000 rows.
If I run the same two statements on a SCO machine running IDS 7.3.UC2
connected to a copy of the same database, I get a count of 2000 from
the first statement while the second statement updates only 1 row.
I executed these statements from dbaccess on both machines.
I re-wrote the second statement as a stored procedure and it works fine
on the SCO machine. I have also tried similar update statements on the
SCO machine and they only update 0 or 1 rows when they should be
updating many more.
Any ideas?
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.