What is the thinking behind a Result.MoveFirst() and MoveNext()
returning a false if a record is there?

So, to read round a result set I end up using a Boolean with a double
negative:

noMoreRows = myResult.MoveFirst()
WHILE NOT noMoreRows
  PRINT myResult!id
  noMoreRows = myResult.MoveNext()
WEND 

I would have expected the MoveFirst() and MoveNext() return true if a
record found, so I'm wondering why it's that way round.
Or, is there a better loop structure to use so that it reads better?


------------------------------------------------------------------------------
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com
_______________________________________________
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to