]> granicus.if.org Git - postgresql/commit
Extend sortsupport for text to more opclasses.
authorRobert Haas <rhaas@postgresql.org>
Wed, 3 Feb 2016 19:17:35 +0000 (14:17 -0500)
committerRobert Haas <rhaas@postgresql.org>
Wed, 3 Feb 2016 19:29:53 +0000 (14:29 -0500)
commitb47b4dbf683f13e6ef09fa0d93aa6e84f3d00819
tree495300ed40d52f5f8f70105a9543697c8d617379
parent24a26c9f5448b24943df4c9bcf154bfd9f8197a6
Extend sortsupport for text to more opclasses.

Have varlena.c expose an interface that allows the char(n), bytea, and
bpchar types to piggyback on a now-generalized SortSupport for text.
This pushes a little more knowledge of the bpchar/char(n) type into
varlena.c than might be preferred, but that seems like the approach
that creates least friction.  Also speed things up for index builds
that use text_pattern_ops or varchar_pattern_ops.

This patch does quite a bit of renaming, but it seems likely to be
worth it, so as to avoid future confusion about the fact that this code
is now more generally used than the old names might have suggested.

Peter Geoghegan, reviewed by Álvaro Herrera and Andreas Karlsson,
with small tweaks by me.
doc/src/sgml/datatype.sgml
src/backend/utils/adt/varchar.c
src/backend/utils/adt/varlena.c
src/include/catalog/catversion.h
src/include/catalog/pg_amproc.h
src/include/catalog/pg_proc.h
src/include/utils/builtins.h
src/include/utils/bytea.h