1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-07 00:36:50 +03:00

- Fixed variable handling in AT statement.

- Fixed bug that caused segfault when given incorrect DB name.
        - Fixed bug in ecpglib causing indicator to list the size of the
          variable instead of the size of the data.
This commit is contained in:
Michael Meskes
2001-12-05 15:32:07 +00:00
parent 15790465c2
commit ee14711ce8
5 changed files with 41 additions and 19 deletions

View File

@ -35,6 +35,7 @@ exec sql begin declare section;
char name[AMOUNT][8];
char letter[AMOUNT][1];
char command[128];
char *connection="pm";
exec sql end declare section;
exec sql var name is string(AMOUNT);
char msg[128];
@ -94,7 +95,7 @@ exec sql end declare section;
exec sql at pm begin transaction;
strcpy(msg, "select");
exec sql select name, amount, letter into :name, :amount, :letter from "Test";
exec sql select * into :name, :amount, :letter from "Test";
printf("Database: mm\n");
for (i=0, j=sqlca.sqlerrd[2]; i<j; i++)
@ -113,7 +114,7 @@ exec sql end declare section;
}
strcpy(msg, "select");
exec sql at pm select * into :name, :amount, :letter from "Test";
exec sql at :connection select name, amount, letter into :name, :amount, :letter from "Test";
printf("Database: pm\n");
for (i=0, j=sqlca.sqlerrd[2]; i<j; i++)