Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Greenplum
Gpdb
提交
2cbaaee6
G
Gpdb
项目概览
Greenplum
/
Gpdb
通知
7
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
Gpdb
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
2cbaaee6
编写于
6月 20, 2003
作者:
M
Michael Meskes
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Just another Informix compatibility change. They uses "free" for cursors as wellafter closing them.
上级
d9b2401d
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
36 addition
and
5 deletion
+36
-5
src/interfaces/ecpg/ChangeLog
src/interfaces/ecpg/ChangeLog
+4
-0
src/interfaces/ecpg/compatlib/informix.c
src/interfaces/ecpg/compatlib/informix.c
+10
-0
src/interfaces/ecpg/ecpglib/prepare.c
src/interfaces/ecpg/ecpglib/prepare.c
+13
-2
src/interfaces/ecpg/include/ecpg_informix.h
src/interfaces/ecpg/include/ecpg_informix.h
+1
-0
src/interfaces/ecpg/include/ecpglib.h
src/interfaces/ecpg/include/ecpglib.h
+1
-0
src/interfaces/ecpg/preproc/preproc.y
src/interfaces/ecpg/preproc/preproc.y
+5
-2
src/interfaces/ecpg/test/test4.pgc
src/interfaces/ecpg/test/test4.pgc
+2
-1
未找到文件。
src/interfaces/ecpg/ChangeLog
浏览文件 @
2cbaaee6
...
...
@@ -1505,6 +1505,10 @@ Thu Jun 19 10:08:26 CEST 2003
Fri Jun 20 13:23:07 CEST 2003
- Enabled constants in using clause.
Fri Jun 20 15:34:29 CEST 2003
- For Informix compatibility we have to accept a "free <cursor>".
- Set ecpg version to 3.0.0
- Set ecpg library to 4.0.0
- Set pgtypes library to 1.0.0
...
...
src/interfaces/ecpg/compatlib/informix.c
浏览文件 @
2cbaaee6
...
...
@@ -695,6 +695,16 @@ ECPGconnect_informix(int lineno, const char *name, const char *user, const char
return
(
ECPGconnect
(
lineno
,
informix_name
,
user
,
passwd
,
connection_name
,
autocommit
));
}
bool
ECPGdeallocate_informix
(
int
lineno
,
char
*
name
)
{
ECPGdeallocate_one
(
lineno
,
name
);
/* Just ignore all errors since we do not know the list of cursors we
* are allowed to free. We have to trust that the software. */
return
true
;
}
static
struct
var_list
{
int
number
;
...
...
src/interfaces/ecpg/ecpglib/prepare.c
浏览文件 @
2cbaaee6
/* $Header: /cvsroot/pgsql/src/interfaces/ecpg/ecpglib/prepare.c,v 1.
2 2003/06/15 04:07:58 momjian
Exp $ */
/* $Header: /cvsroot/pgsql/src/interfaces/ecpg/ecpglib/prepare.c,v 1.
3 2003/06/20 13:36:34 meskes
Exp $ */
#define POSTGRES_ECPG_INTERNAL
#include "postgres_fe.h"
...
...
@@ -106,6 +106,18 @@ ECPGprepare(int lineno, char *name, char *variable)
/* handle the EXEC SQL DEALLOCATE PREPARE statement */
bool
ECPGdeallocate
(
int
lineno
,
char
*
name
)
{
bool
ret
=
ECPGdeallocate_one
(
lineno
,
name
);
if
(
!
ret
)
ECPGraise
(
lineno
,
ECPG_INVALID_STMT
,
name
);
return
ret
;
}
bool
ECPGdeallocate_one
(
int
lineno
,
char
*
name
)
{
struct
prepared_statement
*
this
,
*
prev
;
...
...
@@ -126,7 +138,6 @@ ECPGdeallocate(int lineno, char *name)
ECPGfree
(
this
);
return
true
;
}
ECPGraise
(
lineno
,
ECPG_INVALID_STMT
,
name
);
return
false
;
}
...
...
src/interfaces/ecpg/include/ecpg_informix.h
浏览文件 @
2cbaaee6
...
...
@@ -34,5 +34,6 @@ extern int byleng(char *, int);
extern
void
ldchar
(
char
*
,
int
,
char
*
);
extern
bool
ECPGconnect_informix
(
int
,
const
char
*
,
const
char
*
,
const
char
*
,
const
char
*
,
int
);
extern
bool
ECPGdeallocate_informix
(
int
,
char
*
);
extern
void
ECPG_informix_set_var
(
int
,
void
*
,
int
);
extern
void
*
ECPG_informix_get_var
(
int
);
src/interfaces/ecpg/include/ecpglib.h
浏览文件 @
2cbaaee6
...
...
@@ -51,6 +51,7 @@ bool ECPGtrans(int, const char *, const char *);
bool
ECPGdisconnect
(
int
,
const
char
*
);
bool
ECPGprepare
(
int
,
char
*
,
char
*
);
bool
ECPGdeallocate
(
int
,
char
*
);
bool
ECPGdeallocate_one
(
int
,
char
*
);
bool
ECPGdeallocate_all
(
int
);
char
*
ECPGprepared_statement
(
char
*
);
...
...
src/interfaces/ecpg/preproc/preproc.y
浏览文件 @
2cbaaee6
/* $Header: /cvsroot/pgsql/src/interfaces/ecpg/preproc/Attic/preproc.y,v 1.23
5 2003/06/20 12:00:59
meskes Exp $ */
/* $Header: /cvsroot/pgsql/src/interfaces/ecpg/preproc/Attic/preproc.y,v 1.23
6 2003/06/20 13:36:34
meskes Exp $ */
/* Copyright comment */
%{
...
...
@@ -674,7 +674,10 @@ stmt: AlterDatabaseSetStmt { output_statement($1, 0, connection); }
}
| ECPGFree
{
fprintf(yyout, "{ ECPGdeallocate(__LINE__, \"%s\");", $1);
if (compat == ECPG_COMPAT_INFORMIX)
fprintf(yyout, "{ ECPGdeallocate_informix(__LINE__, \"%s\");", $1);
else
fprintf(yyout, "{ ECPGdeallocate(__LINE__, \"%s\");", $1);
whenever_action(2);
free($1);
...
...
src/interfaces/ecpg/test/test4.pgc
浏览文件 @
2cbaaee6
...
...
@@ -13,13 +13,14 @@ EXEC SQL BEGIN DECLARE SECTION;
int *did = &i;
int a[10] = {9,8,7,6,5,4,3,2,1,0};
char text[10] = "klmnopqrst";
char *t =
"uvwxyz1234"
;
char *t =
(char *)malloc(10)
;
double f;
bool b = true;
varchar database[3];
EXEC SQL END DECLARE SECTION;
FILE *dbgs;
strcpy(t, "0123456789");
setlocale(LC_ALL, "de_DE");
if ((dbgs = fopen("log", "w")) != NULL)
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录