mirror of
https://github.com/postgres/postgres.git
synced 2025-07-02 09:02:37 +03:00
Avoid an unnecessary syscache lookup in parse_coerce.c.
All the other fields of the constant are being extracted from the syscache entry we already have, so handle collation similarly. (There don't seem to be any other uses for the new function at the moment.)
This commit is contained in:
@ -219,7 +219,7 @@ coerce_type(ParseState *pstate, Node *node,
|
||||
|
||||
newcon->consttype = baseTypeId;
|
||||
newcon->consttypmod = inputTypeMod;
|
||||
newcon->constcollid = get_typcollation(newcon->consttype);
|
||||
newcon->constcollid = typeTypeCollation(targetType);
|
||||
newcon->constlen = typeLen(targetType);
|
||||
newcon->constbyval = typeByVal(targetType);
|
||||
newcon->constisnull = con->constisnull;
|
||||
|
Reference in New Issue
Block a user