Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
7015dfef
Commit
7015dfef
authored
Jan 22, 1998
by
Bruce Momjian
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add LOCK command as DELETE FROM ... WHERE false.
parent
0fd8d601
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
33 additions
and
7 deletions
+33
-7
src/backend/parser/gram.y
src/backend/parser/gram.y
+25
-3
src/backend/parser/keywords.c
src/backend/parser/keywords.c
+2
-1
src/bin/psql/psqlHelp.h
src/bin/psql/psqlHelp.h
+4
-1
src/man/declare.l
src/man/declare.l
+2
-2
No files found.
src/backend/parser/gram.y
View file @
7015dfef
...
...
@@ -10,7 +10,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/parser/gram.y,v 1.9
5 1998/01/20 05:04:07
momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/parser/gram.y,v 1.9
6 1998/01/22 23:04:52
momjian Exp $
*
* HISTORY
* AUTHOR DATE MAJOR EVENT
...
...
@@ -116,7 +116,7 @@ Oid param_type(int t); /* used in parse_expr.c */
CopyStmt, CreateStmt, CreateAsStmt, CreateSeqStmt, DefineStmt, DestroyStmt,
ExtendStmt, FetchStmt, GrantStmt, CreateTrigStmt, DropTrigStmt,
CreatePLangStmt, DropPLangStmt,
IndexStmt, ListenStmt, OptimizableStmt,
IndexStmt, ListenStmt,
LockStmt,
OptimizableStmt,
ProcedureStmt, RecipeStmt, RemoveAggrStmt, RemoveOperStmt,
RemoveFuncStmt, RemoveStmt,
RenameStmt, RevokeStmt, RuleStmt, TransactionStmt, ViewStmt, LoadStmt,
...
...
@@ -276,7 +276,7 @@ Oid param_type(int t); /* used in parse_expr.c */
DATABASE, DELIMITERS, DO, EXPLAIN, EXTEND,
FORWARD, FUNCTION, HANDLER,
INDEX, INHERITS, INSTEAD, ISNULL,
LANCOMPILER, LISTEN, LOAD, LOCATION, MERGE, MOVE,
LANCOMPILER, LISTEN, LOAD, LOC
K_P, LOC
ATION, MERGE, MOVE,
NEW, NONE, NOTHING, NOTNULL, OIDS, OPERATOR, PROCEDURAL,
RECIPE, RENAME, REPLACE, RESET, RETURNS, RULE,
SEQUENCE, SETOF, SHOW, STDIN, STDOUT, TRUSTED,
...
...
@@ -364,6 +364,7 @@ stmt : AddAttrStmt
| GrantStmt
| IndexStmt
| ListenStmt
| LockStmt
| ProcedureStmt
| RecipeStmt
| RemoveAggrStmt
...
...
@@ -2210,6 +2211,27 @@ DeleteStmt: DELETE FROM relation_name
}
;
/*
* Total hack to just lock a table inside a transaction.
* Is it worth making this a separate command, with
* its own node type and file. I don't think so. bjm 1998/1/22
*/
LockStmt: LOCK_P relation_name
{
DeleteStmt *n = makeNode(DeleteStmt);
A_Const *c = makeNode(A_Const);
c->val.type = T_String;
c->val.val.str = "f";
c->typename = makeNode(TypeName);
c->typename->name = xlateSqlType("bool");
n->relname = $2;
n->whereClause = c;
$$ = (Node *)n;
}
;
/*****************************************************************************
*
...
...
src/backend/parser/keywords.c
View file @
7015dfef
...
...
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/parser/keywords.c,v 1.3
1 1998/01/20 05:04:09
momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/parser/keywords.c,v 1.3
2 1998/01/22 23:04:54
momjian Exp $
*
*-------------------------------------------------------------------------
*/
...
...
@@ -127,6 +127,7 @@ static ScanKeyword ScanKeywords[] = {
{
"load"
,
LOAD
},
{
"local"
,
LOCAL
},
{
"location"
,
LOCATION
},
{
"lock"
,
LOCK_P
},
{
"match"
,
MATCH
},
{
"merge"
,
MERGE
},
{
"minute"
,
MINUTE_P
},
...
...
src/bin/psql/psqlHelp.h
View file @
7015dfef
...
...
@@ -5,7 +5,7 @@
*
* Copyright (c) 1994, Regents of the University of California
*
* $Id: psqlHelp.h,v 1.3
8 1998/01/11 20:02:15
momjian Exp $
* $Id: psqlHelp.h,v 1.3
9 1998/01/22 23:05:09
momjian Exp $
*
*-------------------------------------------------------------------------
*/
...
...
@@ -250,6 +250,9 @@ static struct _helpStruct QL_HELP[] = {
{
"load"
,
"dynamically load a module"
,
"load <filename>;"
},
{
"lock"
,
"exclusive lock a table inside a transaction"
,
"lock <class_name>;"
},
{
"move"
,
"move an cursor position"
,
"move [forward|backward] [<number>|all] [in <cursorname>];"
},
...
...
src/man/declare.l
View file @
7015dfef
.\" This is -*-nroff-*-
.\" XXX standard disclaimer belongs here....
.\" $Header: /cvsroot/pgsql/src/man/Attic/declare.l,v 1.
2 1998/01/11 22:17:24
momjian Exp $
.\" $Header: /cvsroot/pgsql/src/man/Attic/declare.l,v 1.
3 1998/01/22 23:05:18
momjian Exp $
.TH FETCH SQL 01/23/93 PostgreSQL PostgreSQL
.SH NAME
decl
e
re - declare a cursor
decl
a
re - declare a cursor
.SH SYNOPSIS
.nf
\fBdeclare\fR [ \fBbinary\fR ] \fBcursor for\fR select statement
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment