Hi Meskes-san There are two points.
(1) I attach a new patch. Please review it. - Preproc replaces any prepared_name to "$0" and changes it to an input-variable for PREARE with typelist and EXECUTE with paramlist. $0 is replaced in ecpg_build_params(). It's enable not to change ECPGdo interface. - Host variables can be used in paramlist of EXECUTE. (2) I found some bugs (two types). I didn't fix them and only avoid bison error. Type1. Bugs or intentional unsupported features. - EXPLAIN EXECUTE - CREATE TABLE AS with using clause e.g. EXPLAIN EXECUTE st; /* It has not been supported before.*/ ExplainableStmt: ExecuteStmt { - $$ = $1; + $$ = $1.name; /* only work arround for bison error */ } Type2. In multi-bytes encoding environment, a part of character of message is cut off. It may be very difficult to fix. I pretend I didn't see it for a while. [ecpglib/error.c] snprintf(sqlca->sqlerrm.sqlerrmc, sizeof(sqlca->sqlerrm.sqlerrmc), "%s on line %d", message, line); sqlca->sqlerrm.sqlerrml = strlen(sqlca->sqlerrm.sqlerrmc); ecpg_log("raising sqlstate %.*s (sqlcode %ld): %s\n", (int) sizeof(sqlca->sqlstate), sqlca->sqlstate, sqlca->sqlcode, sqlca->sqlerrm.sqlerrmc); Regards Ryo Matsumura
ecpg_prepare_as_v1_2.patch
Description: ecpg_prepare_as_v1_2.patch