sqldata/sqlociapi.cpp
// Fetch next portion of data to allocate buffers
Fetch next portion of data to allocate buffers
Fetch next portion of data to allocate buffers
int SqlOciApi::Fetch(int *rows_fetched, size_t *time_spent) 
{
	if(_ociStmtFetch2 == NULL || _ociAttrGet == NULL || _cursor_allocated_rows <= 0)
		return -1;
	TRACE("OCI Fetch() Entered");
	size_t start = GetTickCount();
	int rc = _ociStmtFetch2(_stmtp_cursor, _errhp, (ub4)_cursor_allocated_rows, OCI_DEFAULT, 0, OCI_DEFAULT);
	int fetched = 0;
	_ociAttrGet(_stmtp_cursor, OCI_HTYPE_STMT, (void*)&fetched, NULL, OCI_ATTR_ROWS_FETCHED, _errhp);
	if(rows_fetched != NULL)
		*rows_fetched = fetched;
	if(time_spent != NULL)
		*time_spent = GetTickCount() - start;
	TRACE("OCI Fetch() Left");
	return rc;
}
int SqlOciApi :: Fetch ( int * rows_fetched , size_t * time_spent ) { if ( _ociStmtFetch2 == NULL || _ociAttrGet == NULL || _cursor_allocated_rows <= 0 ) return -1 ; TRACE ( " " ) ; size_t start = GetTickCount ( ) ; int rc = _ociStmtFetch2 ( _stmtp_cursor , _errhp , ( ub4 ) _cursor_allocated_rows , OCI_DEFAULT , 0 , OCI_DEFAULT ) ; int fetched = 0 ; _ociAttrGet ( _stmtp_cursor , OCI_HTYPE_STMT , ( void * ) & fetched , NULL , OCI_ATTR_ROWS_FETCHED , _errhp ) ; if ( rows_fetched != NULL ) * rows_fetched = fetched ; if ( time_spent != NULL ) * time_spent = GetTickCount ( ) - start ; TRACE ( " " ) ; return rc ; }
Fetch next portion of data to allocate buffers
Fetch next portion of data to allocate buffers
// Fetch the data // Get the number of fetched rows