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

Commit7f97e05

Browse files
committed
char* --> Datum
1 parent1ea0172 commit7f97e05

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

‎contrib/spi/refint.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ check_primary_key()
4242
intnargs;/* # of args specified in CREATE TRIGGER */
4343
char**args;/* arguments: column names and table name */
4444
intnkeys;/* # of key columns (= nargs / 2) */
45-
char**kvals;/* key values */
45+
Datum*kvals;/* key values */
4646
char*relname;/* referenced relation name */
4747
Relationrel;/* triggered relation */
4848
HeapTupletuple=NULL;/* tuple to return */
@@ -107,7 +107,7 @@ check_primary_key()
107107
* We use SPI plan preparation feature, so allocate space to place key
108108
* values.
109109
*/
110-
kvals= (char**)palloc(nkeys*sizeof(char*));
110+
kvals= (Datum*)palloc(nkeys*sizeof(Datum));
111111

112112
/*
113113
* Construct ident string as TriggerName $ TriggeredRelationId and try
@@ -228,7 +228,7 @@ check_foreign_key()
228228
intnrefs;/* number of references (== # of plans) */
229229
charaction;/* 'R'estrict | 'S'etnull | 'C'ascade */
230230
intnkeys;/* # of key columns */
231-
char**kvals;/* key values */
231+
Datum*kvals;/* key values */
232232
char*relname;/* referencing relation name */
233233
Relationrel;/* triggered relation */
234234
HeapTupletrigtuple=NULL;/* tuple to being changed */
@@ -310,7 +310,7 @@ check_foreign_key()
310310
* We use SPI plan preparation feature, so allocate space to place key
311311
* values.
312312
*/
313-
kvals= (char**)palloc(nkeys*sizeof(char*));
313+
kvals= (Datum*)palloc(nkeys*sizeof(Datum));
314314

315315
/*
316316
* Construct ident string as TriggerName $ TriggeredRelationId and try
@@ -494,7 +494,7 @@ check_foreign_key()
494494
elog(WARN,"%s: tuple referenced in %s",
495495
trigger->tgname,relname);
496496
}
497-
#ifndefREFINT_QUIET
497+
#ifdefREFINT_VERBOSE
498498
else
499499
elog(NOTICE,"%s: %d tuple(s) of %s are %s",
500500
trigger->tgname,SPI_processed,relname,

‎src/include/executor/spi.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ extern intSPI_result;
7373
externintSPI_connect(void);
7474
externintSPI_finish(void);
7575
externintSPI_exec(char*src,inttcount);
76-
externintSPI_execp(void*plan,char**values,char*Nulls,inttcount);
76+
externintSPI_execp(void*plan,Datum*values,char*Nulls,inttcount);
7777
externvoid*SPI_prepare(char*src,intnargs,Oid*argtypes);
7878
externvoid*SPI_saveplan(void*plan);
7979

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp