Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Greenplum
Gpdb
提交
a7b06f20
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,发现更多精彩内容 >>
提交
a7b06f20
编写于
5月 21, 1999
作者:
M
Michael Meskes
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
*** empty log message ***
上级
96492290
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
17 addition
and
25 deletion
+17
-25
src/interfaces/ecpg/ChangeLog
src/interfaces/ecpg/ChangeLog
+4
-0
src/interfaces/ecpg/preproc/preproc.y
src/interfaces/ecpg/preproc/preproc.y
+13
-25
未找到文件。
src/interfaces/ecpg/ChangeLog
浏览文件 @
a7b06f20
...
...
@@ -582,5 +582,9 @@ Thu May 13 13:51:26 CEST 1999
Mon May 17 18:13:30 CEST 1999
- Synced preproc.y with gram.y.
Fri May 21 18:13:44 CEST 1999
- Synced preproc.y with gram.y.
- Set library version to 3.0.0
- Set ecpg version to 2.6.0
src/interfaces/ecpg/preproc/preproc.y
浏览文件 @
a7b06f20
...
...
@@ -814,7 +814,7 @@ adjust_array(enum ECPGttype type_enum, int *dimension, int *length, int type_dim
%type <str> ViewStmt LoadStmt CreatedbStmt opt_database1 opt_database2 location
%type <str> DestroydbStmt ClusterStmt grantee RevokeStmt encoding
%type <str> GrantStmt privileges operation_commalist operation
%type <str>
cursor_clause opt_cursor opt_readonly opt_of
opt_lmode
%type <str>
opt_cursor
opt_lmode
%type <str> case_expr when_clause_list case_default case_arg when_clause
%type <str> select_clause opt_select_limit select_limit_value
%type <str> select_offset_value table_list using_expr join_expr
...
...
@@ -2724,7 +2724,9 @@ UpdateStmt: UPDATE relation_name
* CURSOR STATEMENTS
*
*****************************************************************************/
CursorStmt: DECLARE name opt_cursor CURSOR FOR SelectStmt cursor_clause
CursorStmt: DECLARE name opt_cursor CURSOR FOR
{ ForUpdateNotAllowed = 1; }
SelectStmt
{
struct cursor *ptr, *this;
...
...
@@ -2744,7 +2746,7 @@ CursorStmt: DECLARE name opt_cursor CURSOR FOR SelectStmt cursor_clause
this->next = cur;
this->name = $2;
this->connection = connection;
this->command = cat
2_str(cat5_str(make1_str("declare"), mm_strdup($2), $3, make1_str("cursor for"), $6
), $7);
this->command = cat
5_str(make1_str("declare"), mm_strdup($2), $3, make1_str("cursor for"
), $7);
this->argsinsert = argsinsert;
this->argsresult = argsresult;
argsinsert = argsresult = NULL;
...
...
@@ -2762,20 +2764,6 @@ opt_cursor: BINARY { $$ = make1_str("binary"); }
| /*EMPTY*/ { $$ = make1_str(""); }
;
cursor_clause: FOR opt_readonly { $$ = cat2_str(make1_str("for"), $2); }
| /*EMPTY*/ { $$ = make1_str(""); }
;
opt_readonly: READ ONLY { $$ = make1_str("read only"); }
| UPDATE opt_of
{
yyerror("DECLARE/UPDATE not supported; Cursors must be READ ONLY.");
}
;
opt_of: OF columnList { $$ = make2_str(make1_str("of"), $2); }
/*****************************************************************************
*
* QUERY:
...
...
@@ -2793,7 +2781,7 @@ opt_of: OF columnList { $$ = make2_str(make1_str("of"), $2); }
SelectStmt: select_clause sort_clause for_update_clause opt_select_limit
{
if (strlen($3) > 0 && ForUpdateNotAllowed != 0)
yyerror("
SELECT
FOR UPDATE is not allowed in this context");
yyerror("FOR UPDATE is not allowed in this context");
ForUpdateNotAllowed = 0;
$$ = cat4_str($1, $2, $3, $4);
...
...
@@ -2941,6 +2929,10 @@ for_update_clause: FOR UPDATE update_list
{
$$ = make1_str("for update");
}
| FOR READ ONLY
{
$$ = make1_str("for read only");
}
| /* EMPTY */
{
$$ = make1_str("");
...
...
@@ -3356,11 +3348,7 @@ Character: character '(' Iconst ')'
yyerror(errortext);
}
else if (atol($3) > BLCKSZ - 128) {
/* we can store a char() of length up to the size
* of a page (8KB) - page headers and friends but
* just to be safe here... - ay 6/95
*/
sprintf(errortext, "length for type '%s' cannot exceed %d",BLCKSZ-128);
sprintf(errortext, "length for type '%s' cannot exceed %d",$1,BLCKSZ - 128);
yyerror(errortext);
}
...
...
@@ -4721,7 +4709,7 @@ opt_options: Op ColId
* Declare a prepared cursor. The syntax is different from the standard
* declare statement, so we create a new rule.
*/
ECPGCursorStmt: DECLARE name opt_cursor CURSOR FOR ident
cursor_clause
ECPGCursorStmt: DECLARE name opt_cursor CURSOR FOR ident
{
struct cursor *ptr, *this;
struct variable *thisquery = (struct variable *)mm_alloc(sizeof(struct variable));
...
...
@@ -4742,7 +4730,7 @@ ECPGCursorStmt: DECLARE name opt_cursor CURSOR FOR ident cursor_clause
this->next = cur;
this->name = $2;
this->connection = connection;
this->command = cat
5_str(make1_str("declare"), mm_strdup($2), $3, make1_str("cursor for ?"), $7
);
this->command = cat
4_str(make1_str("declare"), mm_strdup($2), $3, make1_str("cursor for ?")
);
this->argsresult = NULL;
thisquery->type = &ecpg_query;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录