-
-
Notifications
You must be signed in to change notification settings - Fork 221
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"request synchronization error" when calling isc_dsql_sql_info with isc_info_sql_records parameter after last record fetched with "execute procedure" [CORE2154] #2585
Comments
Commented by: Thiago Borges (thborges) I modified the example provided in CORE1310 to use "execute procedure" and the error reappear. |
Modified by: Thiago Borges (thborges)Attachment: testit.cpp [ 11130 ] |
Modified by: Thiago Borges (thborges)Version: 2.1.1 [ 10223 ] Version: 2.5 Alpha 1 [ 10224 ] description: I getting this error always when a table contains the fields with double precision data type and has at least a few hudreds records. Everything is ok if a table does not have double precision data type fields, or there are a few records in it, or double precision fileds are not used in a query. Last problem bulid tested: LI-T2.1.0.15947 Firebird 2.1 Beta 1 Test: create database 'localhost:/tmp/testdb.fdb' page_size=16384; CREATE TABLE "TEST" /*testit.cpp*/ #define ERREXIT(status, rc) {isc_print_status(status); return rc;} isc_db_handle db = NULL; void free_sqlda(XSQLDA *sqlda) { void set_sqlda(XSQLDA *sqlda) { sqlda->sqlvar[i].sqlind = (short*)calloc(sizeof(short),1); int affectedRows(int * sCnt=0,int * uCnt=0, int * iCnt=0, int *dCnt=0) { selectCount=insertCount=updateCount=deleteCount=0; isc_dsql_sql_info(status, &stmt, p=info_buffer+3;
} affected_rows = selectCount+updateCount+insertCount+deleteCount; return affected_rows; int main (int argc, char** argv) char dbname[]="localhost:/tmp/testdb.fdb";
} /*Makefile*/ OBJS = testit.o .cpp.o: testit: $(OBJS) /*http://runit.sh*/ if [ "${ISC_USER}" == "" ] if [ "${ISC_PASSWORD}" == "" ] } clear make || exit -1 echo if [ ! -f /tmp/testdb.fdb ] ./testit => I got "request syncronization error" when calling isc_dsql_sql_info after EOF was reached. This error appear in CORE1310, and was solved in 2.1 Beta 1 for "select * from table". With fbclient.dll 2.0.4.13130 all seems ok. environment: Debian Linux Sarge 3.1, gcc 3.3.5 => Windows/VC++ 8 Version: 2.1 Beta 1 [ 10141 ] => |
Commented by: @hvlad > I got "request syncronization error" when calling isc_dsql_sql_info after EOF was reached. And this is perfectly valid. What else you expected ? |
Commented by: @hvlad Hmm... your test case is not correct as you must not fetch from "execute procedure" request. |
Commented by: Thiago Borges (thborges) Sorry, I try to say: The SQL command return 1 row. The first call to isc_dsql_fetch return 0 |
Commented by: @hvlad You should read at least documentation for IB6 to understand statement type and how statements of different types must be prepared and executed. From another POV we may return EOF on second fetch and only after it isc_req_sync for such scenario. |
Commented by: @hvlad Conclusion is : when engine executed non-select statement, i.e. statement which have no cursor, it must disallow fetch from such statement handle. This check will be implemented in 2.5 engine only to allow bad application work untouched with current Firebird versions. > From another POV we may return EOF on second fetch and only after it isc_req_sync for such scenario. > I'll look for behavior of fbclient before 2.1 and came back with my conclusion |
Modified by: @hvladstatus: Open [ 1 ] => Resolved [ 5 ] resolution: Fixed [ 1 ] Fix Version: 2.5 Beta 1 [ 10251 ] Fix Version: 2.1 Beta 1 [ 10141 ] => |
Modified by: @pcisarstatus: Resolved [ 5 ] => Closed [ 6 ] |
Modified by: @pavel-zotovQA Status: No test |
Submitted by: Thiago Borges (thborges)
Attachments:
testit.cpp
I got "request syncronization error" when calling isc_dsql_sql_info after EOF was reached.
This error appear in CORE1310, and was solved in 2.1 Beta 1 for "select * from table".
But I getting the error now running "execute procedure X(P)"
With fbclient.dll 2.0.4.13130 all seems ok.
Commits: 285879c 5fdc028
The text was updated successfully, but these errors were encountered: