Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit864e1e9

Browse files
author
Michael Meskes
committed
*** empty log message ***
1 parent3f68139 commit864e1e9

File tree

9 files changed

+23
-10
lines changed

9 files changed

+23
-10
lines changed

‎src/interfaces/ecpg/ChangeLog

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -622,3 +622,12 @@ Sun Aug 1 13:31:19 CEST 1999
622622

623623
- Synced preproc.y with gram.y.
624624
- Set ecpg version to 2.6.2
625+
626+
Tue Sep 14 22:26:40 CEST 1999
627+
628+
- Added patch by Andreas Theofilu <theofilu@eunet.at> to fix yet
629+
another quoting bug.
630+
- Minor bugfixes to ecpg
631+
- Return OID in sqlca.sqlerrd[1] if possible.
632+
- Set ecpg version to 2.6.3
633+
- Set library version to 3.0.2

‎src/interfaces/ecpg/TODO

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ support for dynamic SQL with unknown number of variables with DESCRIPTORS
1414
The line numbering is not exact.
1515

1616
Missing statements:
17+
- exec slq ifdef
1718
- exec sql allocate
1819
- exec sql deallocate
1920
- SQLSTATE

‎src/interfaces/ecpg/include/sqlca.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ extern"C"
1919
charsqlerrp[8];
2020
longsqlerrd[6];
2121
/* Element 0: empty*/
22-
/* 1:empty*/
22+
/* 1: OID of processed tuple if applicable*/
2323
/* 2: number of rows processed*/
2424
/* after an INSERT, UPDATE or */
2525
/* DELETE statement */

‎src/interfaces/ecpg/lib/Makefile.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@
66
# Copyright (c) 1994, Regents of the University of California
77
#
88
# IDENTIFICATION
9-
# $Header: /cvsroot/pgsql/src/interfaces/ecpg/lib/Attic/Makefile.in,v 1.45 1999/07/19 12:37:46 meskes Exp $
9+
# $Header: /cvsroot/pgsql/src/interfaces/ecpg/lib/Attic/Makefile.in,v 1.46 1999/09/15 08:29:14 meskes Exp $
1010
#
1111
#-------------------------------------------------------------------------
1212

1313
NAME= ecpg
1414
SO_MAJOR_VERSION= 3
15-
SO_MINOR_VERSION= 0.1
15+
SO_MINOR_VERSION= 0.2
1616

1717
SRCDIR= @top_srcdir@
1818
include$(SRCDIR)/Makefile.global

‎src/interfaces/ecpg/lib/ecpglib.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,7 @@ next_insert(char *text)
368368
boolstring= false;
369369

370370
for (;*ptr!='\0'&& (*ptr!='?'||string);ptr++)
371-
if (*ptr=='\'')
371+
if (*ptr=='\''&&*(ptr-1)!='\\')
372372
string=string ? false : true;
373373

374374
return (*ptr=='\0') ?NULL :ptr;
@@ -977,6 +977,7 @@ ECPGexecute(struct statement * stmt)
977977
break;
978978
casePGRES_COMMAND_OK:
979979
status= true;
980+
sqlca.sqlerrd[1]=atol(PQoidStatus(results));
980981
sqlca.sqlerrd[2]=atol(PQcmdTuples(results));
981982
ECPGlog("ECPGexecute line %d Ok: %s\n",stmt->lineno,PQcmdStatus(results));
982983
break;

‎src/interfaces/ecpg/preproc/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ include $(SRCDIR)/Makefile.global
33

44
MAJOR_VERSION=2
55
MINOR_VERSION=6
6-
PATCHLEVEL=2
6+
PATCHLEVEL=3
77

88
CFLAGS+=-I../include -DMAJOR_VERSION=$(MAJOR_VERSION)\
99
-DMINOR_VERSION=$(MINOR_VERSION) -DPATCHLEVEL=$(PATCHLEVEL)\

‎src/interfaces/ecpg/preproc/pgc.l

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ cppline{space}*#.*(\\{space}*\n)*\n*
239239
}
240240
<xq>{xqstop}{
241241
BEGIN(SQL);
242-
/* yylval.str = scanstr(literal);*/
242+
/* yylval.str =mm_strdup(scanstr(literal));*/
243243
yylval.str =mm_strdup(literal);
244244
return SCONST;
245245
}
@@ -601,7 +601,7 @@ cppline{space}*#.*(\\{space}*\n)*\n*
601601
if (strcmp(old, ptr->old) ==0)
602602
{
603603
free(ptr->new);
604-
/* ptr->new = scanstr(literal);*/
604+
/* ptr->new =mm_strdup(scanstr(literal));*/
605605
ptr->new =mm_strdup(literal);
606606
}
607607
}
@@ -611,7 +611,7 @@ cppline{space}*#.*(\\{space}*\n)*\n*
611611

612612
/* initial definition */
613613
this->old = old;
614-
/* this->new = scanstr(literal);*/
614+
/* this->new =mm_strdup(scanstr(literal));*/
615615
this->new =mm_strdup(literal);
616616
this->next = defines;
617617
defines =this;

‎src/interfaces/ecpg/preproc/preproc.y

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1142,7 +1142,7 @@ VariableSetStmt: SET ColId TO var_value
11421142
}
11431143
|SETNAMESencoding
11441144
{
1145-
#ifdefMB
1145+
#ifdefMULTIBYTE
11461146
$$ = cat2_str(make1_str("set names"), $3);
11471147
#else
11481148
yyerror("SET NAMES is not supported");

‎src/interfaces/ecpg/test/test1.pgc

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,9 @@ exec sql end declare section;
4848
strcpy(msg, "execute insert 1");
4949
sprintf(command, "insert into test(name, amount, letter) values ('db: ''mm''', 1, 'f')");
5050
exec sql execute immediate :command;
51-
sprintf(command, "insert into test(name, amount, letter) values ('db: ''mm''', 2, 't')");
51+
printf("New tuple got OID = %d\n", sqlca.sqlerrd[1]);
52+
53+
sprintf(command, "insert into test(name, amount, letter) values ('db: \\\'mm\\\'', 2, 't')");
5254
exec sql execute immediate :command;
5355

5456
strcpy(msg, "execute insert 2");

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp