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

Commitdeb66e0

Browse files
committed
1 parent0ca9907 commitdeb66e0

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

‎src/backend/access/gin/ginscan.c

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Portions Copyright (c) 1994, Regents of the University of California
99
*
1010
* IDENTIFICATION
11-
* $PostgreSQL: pgsql/src/backend/access/gin/ginscan.c,v 1.4 2006/08/03 15:22:09 tgl Exp $
11+
* $PostgreSQL: pgsql/src/backend/access/gin/ginscan.c,v 1.5 2006/09/14 11:26:49 teodor Exp $
1212
*-------------------------------------------------------------------------
1313
*/
1414

@@ -127,6 +127,11 @@ newScanKey( IndexScanDesc scan ) {
127127

128128
so->keys= (GinScanKey)palloc(scan->numberOfKeys*sizeof(GinScanKeyData) );
129129

130+
if (scan->numberOfKeys<1)
131+
ereport(ERROR,
132+
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
133+
errmsg("GIN indexes do not support whole-index scans")));
134+
130135
for(i=0;i<scan->numberOfKeys;i++) {
131136
Datum*entryValues;
132137
uint32nEntryValues;
@@ -155,7 +160,9 @@ newScanKey( IndexScanDesc scan ) {
155160
so->nkeys=nkeys;
156161

157162
if (so->nkeys==0 )
158-
elog(ERROR,"Gin doesn't support full scan due to it's awful inefficiency");
163+
ereport(ERROR,
164+
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
165+
errmsg("GIN index doesn't support search with void query")));
159166

160167
pgstat_count_index_scan(&scan->xs_pgstat_info);
161168
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp