DatabaseRetrieve [sql], rows LoopWhile rows, END_LOOP DatabaseGet(rows, 1, db_payid) // do something of value with the payer id Subtract rows, 1, rows END_LOOP: Couple other tips: -- If you just want to transfer data, use the DatabasePipe statement -- If you want to transfer data with some simple conversion, create a view in the source database and then use the DatabasePipe. In the view implement the required conversion logic using available SQL functions. -- If your source data is stored in MS SQL Server or Sybase SQL Server, or SQL Anywhere database you can also use stored procedure as a data source for the DatabaseRetrieve. This might be handy in some cases. : Hi - : Is there a prefered method for processing all rows of a SQL answerset? I am : converting our old tracking databases into SQL2000, and need to perform : various tasks based on entried found in the database. : rs.open "select PayIDs from Ops;" // 5 to 20 rows returned : do while not rs.EOF : DatabaseGet(???, 1, db_payid) : // do something of value with the payer id : loop : rs.close
|