mirror of
https://git.postgresql.org/git/postgresql.git
synced 2025-01-06 15:24:56 +08:00
7844608e54
contrib/pg_trgm's make_trigrams() was coded to ignore multibyte character boundaries and just make trigrams from bytes if USE_WIDE_UPPER_LOWER wasn't defined. This is a bit odd, since there's no obvious reason why trigram compaction rules should depend on the presence of towlower() and friends. What's more, there was an Assert() that would fail if that code path was fed any multibyte characters. We need to do something about this since the pending regex-indexing patch has an assumption that you get just one "trgm" from any three characters. The best solution seems to be to remove the USE_WIDE_UPPER_LOWER dependency, which shouldn't really have been there in the first place. The second loop in make_trigrams() is now just a fast path and not a potentially incompatible algorithm. If there is anybody still using Postgres on machines without wcstombs() or towlower(), and they have non-ASCII data indexed by pg_trgm, they'll need to REINDEX those indexes after pg_upgrade to 9.3, else searches may fail incorrectly. It seems likely that there are no such installations, though. In passing, rename cnt_trigram to compact_trigram, which seems to better describe its functionality, and improve make_trigrams' test for whether it has to use the slow path or not (per a suggestion from Alexander Korotkov). |
||
---|---|---|
.. | ||
adminpack | ||
auth_delay | ||
auto_explain | ||
btree_gin | ||
btree_gist | ||
chkpass | ||
citext | ||
cube | ||
dblink | ||
dict_int | ||
dict_xsyn | ||
dummy_seclabel | ||
earthdistance | ||
file_fdw | ||
fuzzystrmatch | ||
hstore | ||
intagg | ||
intarray | ||
isn | ||
lo | ||
ltree | ||
oid2name | ||
pageinspect | ||
passwordcheck | ||
pg_archivecleanup | ||
pg_buffercache | ||
pg_freespacemap | ||
pg_standby | ||
pg_stat_statements | ||
pg_test_fsync | ||
pg_test_timing | ||
pg_trgm | ||
pg_upgrade | ||
pg_upgrade_support | ||
pg_xlogdump | ||
pgbench | ||
pgcrypto | ||
pgrowlocks | ||
pgstattuple | ||
postgres_fdw | ||
seg | ||
sepgsql | ||
spi | ||
sslinfo | ||
start-scripts | ||
tablefunc | ||
tcn | ||
test_parser | ||
tsearch2 | ||
unaccent | ||
uuid-ossp | ||
vacuumlo | ||
worker_spi | ||
xml2 | ||
contrib-global.mk | ||
Makefile | ||
README |
The PostgreSQL contrib tree --------------------------- This subtree contains porting tools, analysis utilities, and plug-in features that are not part of the core PostgreSQL system, mainly because they address a limited audience or are too experimental to be part of the main source tree. This does not preclude their usefulness. User documentation for each module appears in the main SGML documentation. When building from the source distribution, these modules are not built automatically, unless you build the "world" target. You can also build and install them all by running "gmake all" and "gmake install" in this directory; or to build and install just one selected module, do the same in that module's subdirectory. Some directories supply new user-defined functions, operators, or types. To make use of one of these modules, after you have installed the code you need to register the new SQL objects in the database system by executing a CREATE EXTENSION command. In a fresh database, you can simply do CREATE EXTENSION module_name; See the PostgreSQL documentation for more information about this procedure.