Re: [PHP-WIN] Problem with CURSOR under MS SQL 7

2001-01-11 Thread Thomas
Hello Mauro, Sorry! As you maybe have seen, this is another version than the "countermove-select" (bloody copypaste :), but should work anyway. Cu, Thomas Thomas wrote: > Hello Mauro, > > I don't know exactly why your Cursor doesn't work (e.g. a SET . desn't work > yet also, but will be i

Re: [PHP-WIN] Problem with CURSOR under MS SQL 7

2001-01-11 Thread Thomas
Hello Mauro, I don't know exactly why your Cursor doesn't work (e.g. a SET . desn't work yet also, but will be in the next version). Since you just want simulate the LIMIT (x,y) from mySQL, here's the way I've done it (Simple "countermove-Select"): SELECT TOP $limit WITH TIES * FROM $table W

[PHP-WIN] Problem with CURSOR under MS SQL 7

2001-01-10 Thread Mauro Boschi
Hi, I'm trying to understand why something like this: DECLARE crs CURSOR KEYSET FOR SELECT title FROM article WHERE pub_id = 1 OPEN crs FETCH ABSOLUTE 3 FROM crs DECLARE @var INT SET @var = 0 WHILE (@var<10) BEGIN FETCH NEXT FROM crs SET @var = @var +1 END CLOSE crs DEALLOCATE crs Doesn't work