Database Reference
In-Depth Information
fuzzystrmatch
A lightweight extension with functions such as soundex , levenshtein , and meta
phone for fuzzy string matching. We discuss its use in Where is Soundex and Other
Warm and Fuzzy Things .
hstore
An extension that adds key-value pair storage and index support, well-suited for
storing pseudonormalized data. If you are looking for a comfortable medium be‐
tween a relational database and NoSQL, check out hstore.
pg_trgm (trigram)
Another fuzzy string search library, used in conjunction with fuzzystrmatch. In
version 9.1, it adds a new operator class, making searches using the ILIKE operator
indexable. trigram can also index wildcard searches in the form of LIKE '% some
thing %' . See Teaching ILIKE and LIKE New Tricks for further discussion.
dblink
Allows you to query a PostgreSQL database on another server. Prior to the intro‐
duction of foreign data wrappers in version 9.3, this was the only supported mech‐
anism for cross-database interactions. It remains useful for one-time connections
or ad hoc queries. When we have to restore an old database backup to cull acci‐
dentally deleted data, we use dblink to connect from the current database to its
restored backup.
pgcrypto
Provides encryption tools, including the popular PGP. It's handy for encrypting
credit card numbers and other top secret information stored in the database. We
placed a quick primer on it at Encrypting Data with pgcrypto .
Classic extensions
Here we mention a couple extensions that have gained enough of a following to make
it into official PostgreSQL releases. We call them out them here because you could still
run into them as separate extensions on older servers:
tsearch
A suite of indexes, operators, custom dictionaries, and functions that enhance full-
text searches. It is now part of PostgreSQL proper. If you're still relying on behavior
in from the old extension, you can install tsearch2 . A better tactic would be just to
update servers where you're using the old functions, because compatibility could
end at any time.
xml
An extension that added an XML data type, related functions, and operators. The
XML data type is now an integral part of PostgreSQL, in part to meet the ANSI SQL
XML standard. The old extension, now dubbed xml2 , can still be installed and
Search WWH ::




Custom Search