Purpose
Determines whether the end of the result table has been reached via a Server Fetch statement. You can call this function from the MapBasic window in MapInfo Pro.
Syntax
Server_EOT( StatementNumber )
StatementNumber is the number of the Server Fetch statement you are checking.
Return Value
Logical
Description
The Server_EOT() function returns TRUE or FALSE indicating whether the previous Server Fetch statement encountered a condition where there was no more data to return. Attempting to fetch a previous record immediately after fetching the first record causes this to return TRUE. Attempting to fetch the next record after the last record also returns a value of TRUE.
Example
Dim hdbc, hstmt As Integer
hdbc = Server_Connect("ODBC", "DLG=1")
hstmt = Server_Execute(hdbc, "Select * from ADDR")
Server hstmt Fetch FIRST
While Not Server_EOT(hstmt)
' Processing for each row of data ...
Server hstmt Fetch Next
Wend
See Also:
Server Fetch statement