@@ -2149,31 +2149,31 @@ CheckSelectLocking(Query *qry)
2149
2149
if (qry -> setOperations )
2150
2150
ereport (ERROR ,
2151
2151
(errcode (ERRCODE_FEATURE_NOT_SUPPORTED ),
2152
- errmsg ("SELECT FOR UPDATE/SHARE/FOR KEY UPDATE/FOR KEY SHARE is not allowed with UNION/INTERSECT/EXCEPT" )));
2152
+ errmsg ("row-level locks are not allowed with UNION/INTERSECT/EXCEPT" )));
2153
2153
if (qry -> distinctClause != NIL )
2154
2154
ereport (ERROR ,
2155
2155
(errcode (ERRCODE_FEATURE_NOT_SUPPORTED ),
2156
- errmsg ("SELECT FOR UPDATE/SHARE/FOR KEY UPDATE/FOR KEY SHARE is not allowed with DISTINCT clause" )));
2156
+ errmsg ("row-level locks are not allowed with DISTINCT clause" )));
2157
2157
if (qry -> groupClause != NIL )
2158
2158
ereport (ERROR ,
2159
2159
(errcode (ERRCODE_FEATURE_NOT_SUPPORTED ),
2160
- errmsg ("SELECT FOR UPDATE/SHARE/FOR KEY UPDATE/FOR KEY SHARE is not allowed with GROUP BY clause" )));
2160
+ errmsg ("row-level locks are not allowed with GROUP BY clause" )));
2161
2161
if (qry -> havingQual != NULL )
2162
2162
ereport (ERROR ,
2163
2163
(errcode (ERRCODE_FEATURE_NOT_SUPPORTED ),
2164
- errmsg ("SELECT FOR UPDATE/SHARE/FOR KEY UPDATE/FOR KEY SHARE is not allowed with HAVING clause" )));
2164
+ errmsg ("row-level locks are not allowed with HAVING clause" )));
2165
2165
if (qry -> hasAggs )
2166
2166
ereport (ERROR ,
2167
2167
(errcode (ERRCODE_FEATURE_NOT_SUPPORTED ),
2168
- errmsg ("SELECT FOR UPDATE/SHARE/FOR KEY UPDATE/FOR KEY SHARE is not allowed with aggregate functions" )));
2168
+ errmsg ("row-level locks are not allowed with aggregate functions" )));
2169
2169
if (qry -> hasWindowFuncs )
2170
2170
ereport (ERROR ,
2171
2171
(errcode (ERRCODE_FEATURE_NOT_SUPPORTED ),
2172
- errmsg ("SELECT FOR UPDATE/SHARE/FOR KEY UPDATE/FOR KEY SHARE is not allowed with window functions" )));
2172
+ errmsg ("row-level locks are not allowed with window functions" )));
2173
2173
if (expression_returns_set ((Node * ) qry -> targetList ))
2174
2174
ereport (ERROR ,
2175
2175
(errcode (ERRCODE_FEATURE_NOT_SUPPORTED ),
2176
- errmsg ("SELECT FOR UPDATE/SHARE/FOR KEY UPDATE/FOR KEY SHARE is not allowed with set-returning functions in the target list" )));
2176
+ errmsg ("row-level locks are not allowed with set-returning functions in the target list" )));
2177
2177
}
2178
2178
2179
2179
/*
@@ -2252,7 +2252,7 @@ transformLockingClause(ParseState *pstate, Query *qry, LockingClause *lc,
2252
2252
if (thisrel -> catalogname || thisrel -> schemaname )
2253
2253
ereport (ERROR ,
2254
2254
(errcode (ERRCODE_SYNTAX_ERROR ),
2255
- errmsg ("SELECT FOR UPDATE/SHARE/KEY UPDATE/KEY SHARE must specify unqualified relation names" ),
2255
+ errmsg ("row-level locks must specify unqualified relation names" ),
2256
2256
parser_errposition (pstate , thisrel -> location )));
2257
2257
2258
2258
i = 0 ;
@@ -2269,7 +2269,7 @@ transformLockingClause(ParseState *pstate, Query *qry, LockingClause *lc,
2269
2269
if (rte -> relkind == RELKIND_FOREIGN_TABLE )
2270
2270
ereport (ERROR ,
2271
2271
(errcode (ERRCODE_FEATURE_NOT_SUPPORTED ),
2272
- errmsg ("SELECT FOR UPDATE/SHARE/KEY UPDATE/KEY SHARE cannot be used with foreign table \"%s\"" ,
2272
+ errmsg ("row-level locks cannot be used with foreign table \"%s\"" ,
2273
2273
rte -> eref -> aliasname ),
2274
2274
parser_errposition (pstate , thisrel -> location )));
2275
2275
applyLockingClause (qry , i ,
@@ -2288,25 +2288,25 @@ transformLockingClause(ParseState *pstate, Query *qry, LockingClause *lc,
2288
2288
case RTE_JOIN :
2289
2289
ereport (ERROR ,
2290
2290
(errcode (ERRCODE_FEATURE_NOT_SUPPORTED ),
2291
- errmsg ("SELECT FOR UPDATE/SHARE/KEY UPDATE/KEY SHARE cannot be applied to a join" ),
2291
+ errmsg ("row-level locks cannot be applied to a join" ),
2292
2292
parser_errposition (pstate , thisrel -> location )));
2293
2293
break ;
2294
2294
case RTE_FUNCTION :
2295
2295
ereport (ERROR ,
2296
2296
(errcode (ERRCODE_FEATURE_NOT_SUPPORTED ),
2297
- errmsg ("SELECT FOR UPDATE/SHARE/KEY UPDATE/KEY SHARE cannot be applied to a function" ),
2297
+ errmsg ("row-level locks cannot be applied to a function" ),
2298
2298
parser_errposition (pstate , thisrel -> location )));
2299
2299
break ;
2300
2300
case RTE_VALUES :
2301
2301
ereport (ERROR ,
2302
2302
(errcode (ERRCODE_FEATURE_NOT_SUPPORTED ),
2303
- errmsg ("SELECT FOR UPDATE/SHARE/KEY UPDATE/KEY SHARE cannot be applied to VALUES" ),
2303
+ errmsg ("row-level locks cannot be applied to VALUES" ),
2304
2304
parser_errposition (pstate , thisrel -> location )));
2305
2305
break ;
2306
2306
case RTE_CTE :
2307
2307
ereport (ERROR ,
2308
2308
(errcode (ERRCODE_FEATURE_NOT_SUPPORTED ),
2309
- errmsg ("SELECT FOR UPDATE/SHARE/KEY UPDATE/KEY SHARE cannot be applied to a WITH query" ),
2309
+ errmsg ("row-level locks cannot be applied to a WITH query" ),
2310
2310
parser_errposition (pstate , thisrel -> location )));
2311
2311
break ;
2312
2312
default :
@@ -2320,7 +2320,7 @@ transformLockingClause(ParseState *pstate, Query *qry, LockingClause *lc,
2320
2320
if (rt == NULL )
2321
2321
ereport (ERROR ,
2322
2322
(errcode (ERRCODE_UNDEFINED_TABLE ),
2323
- errmsg ("relation \"%s\" in FOR UPDATE/SHARE/KEY UPDATE/KEY SHARE clause not found in FROM clause" ,
2323
+ errmsg ("relation \"%s\" in row-level lock clause not found in FROM clause" ,
2324
2324
thisrel -> relname ),
2325
2325
parser_errposition (pstate , thisrel -> location )));
2326
2326
}
0 commit comments