Sqlnext
![]() |
Fetches the next record in a multi-row query initiated with Sqlcursor. |
Supported Script Types
Properties
Property | Details |
---|---|
TimeoutSec | The amount of seconds that the action waits to execute before timing out. The value must be between 0 and 60. |
Branches
Branch | Details |
---|---|
Default |
Path taken unless the script meets a condition that requires it to take one of the other branches. It is also taken if the other branches are not defined. |
EndOfDataset |
Path taken once the last row has been fetched and there is another occurrence of Sqlnext. Once triggered, the dataset will automatically be closed. Always use Sqlclose before the end of the script. |
Tips & Tricks
- Sqlnext does nothing if a query has not been opened with Sqlcursor.
- A Loop action is typically used to repetitively call the Sqlnext. As long as more data exists to fetch, the Default branch condition of the Sqlnext will be triggered. The End Of Dataset branch condition will be triggered when Sqlnext is executed and there are no remaining records.
- If 3 records from a query were being fetched:
- Sqlnext would fetch the first row.
- Two iterations of Sqlnext would retrieve the next two rows.
- A third iteration would trigger the End Of Dataset branch condition off of the Sqlnext action.