git.postgresql.org Git - postgresql.git/commit

git projects / postgresql.git / commit
? search:
summary | shortlog | log | commit | commitdiff | tree
(parent: 070c3d3) | patch
Add SQL functions for Unicode normalization
2020年3月26日 07:14:00 +0000 (08:14 +0100)
Thu, 2 Apr 2020 06:56:27 +0000 (08:56 +0200)
commit 2991ac5fc9b3904ca4582be6d323497d7c3d17c9
Add SQL functions for Unicode normalization

This adds SQL expressions NORMALIZE() and IS NORMALIZED to convert and
check Unicode normal forms, per SQL standard.

To support fast IS NORMALIZED tests, we pull in a new data file
DerivedNormalizationProps.txt from Unicode and build a lookup table
from that, using techniques similar to ones already used for other
Unicode data. make update-unicode will keep it up to date. We only
build and use these tables for the NFC and NFKC forms, because they
are too big for NFD and NFKD and the improvement is not significant
enough there.

Reviewed-by: Daniel Verite <daniel@manitou-mail.org>
Reviewed-by: Andreas Karlsson <andreas@proxel.se>
Discussion: https://www.postgresql.org/message-id/flat/c1909f27-c269-2ed9-12f8-3ab72c8caf7a@2ndquadrant.com
20 files changed:
doc/src/sgml/charset.sgml diff | blob | blame | history
doc/src/sgml/func.sgml diff | blob | blame | history
src/backend/catalog/sql_features.txt diff | blob | blame | history
src/backend/catalog/system_views.sql diff | blob | blame | history
src/backend/parser/gram.y diff | blob | blame | history
src/backend/utils/adt/varlena.c diff | blob | blame | history
src/common/unicode/.gitignore diff | blob | blame | history
src/common/unicode/Makefile diff | blob | blame | history
src/common/unicode/generate-unicode_normprops_table.pl [new file with mode: 0644] blob
src/common/unicode_norm.c diff | blob | blame | history
src/include/catalog/catversion.h diff | blob | blame | history
src/include/catalog/pg_proc.dat diff | blob | blame | history
src/include/common/unicode_norm.h diff | blob | blame | history
src/include/common/unicode_normprops_table.h [new file with mode: 0644] blob
src/include/parser/kwlist.h diff | blob | blame | history
src/test/regress/expected/unicode.out [new file with mode: 0644] blob
src/test/regress/expected/unicode_1.out [new file with mode: 0644] blob
src/test/regress/parallel_schedule diff | blob | blame | history
src/test/regress/serial_schedule diff | blob | blame | history
src/test/regress/sql/unicode.sql [new file with mode: 0644] blob
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /