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
682b1289
Commit
682b1289
authored
Jan 06, 2001
by
Tom Lane
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix NOT NULL option for plpgsql variables (doesn't look like it
could ever have worked...)
parent
0ad5e437
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
7 deletions
+9
-7
src/pl/plpgsql/src/pl_exec.c
src/pl/plpgsql/src/pl_exec.c
+9
-7
No files found.
src/pl/plpgsql/src/pl_exec.c
View file @
682b1289
...
...
@@ -3,7 +3,7 @@
* procedural language
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/pl/plpgsql/src/pl_exec.c,v 1.3
4 2001/01/04 02:38:02
tgl Exp $
* $Header: /cvsroot/pgsql/src/pl/plpgsql/src/pl_exec.c,v 1.3
5 2001/01/06 01:43:01
tgl Exp $
*
* This software is copyrighted by Jan Wieck - Hamburg.
*
...
...
@@ -2210,6 +2210,7 @@ exec_assign_value(PLpgSQL_execstate * estate,
int
natts
;
Datum
*
values
;
char
*
nulls
;
Datum
newvalue
;
bool
attisnull
;
Oid
atttype
;
int32
atttypmod
;
...
...
@@ -2225,15 +2226,16 @@ exec_assign_value(PLpgSQL_execstate * estate,
* ----------
*/
var
=
(
PLpgSQL_var
*
)
target
;
var
->
value
=
exec_cast_value
(
value
,
valtype
,
var
->
datatype
->
typoid
,
&
(
var
->
datatype
->
typinput
),
var
->
datatype
->
typelem
,
var
->
datatype
->
atttypmod
,
isNull
);
new
value
=
exec_cast_value
(
value
,
valtype
,
var
->
datatype
->
typoid
,
&
(
var
->
datatype
->
typinput
),
var
->
datatype
->
typelem
,
var
->
datatype
->
atttypmod
,
isNull
);
if
(
isNull
&&
var
->
notnull
)
if
(
*
isNull
&&
var
->
notnull
)
elog
(
ERROR
,
"NULL assignment to variable '%s' declared NOT NULL"
,
var
->
refname
);
var
->
value
=
newvalue
;
var
->
isnull
=
*
isNull
;
break
;
...
...
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