DROP_COLLATION(7pg17)
okay so welcome to DROP_COLLATION(7pg17), straight out of the PostgreSQL 17.11 docs π
this one is short, sweet, and very βknow your ownership before you yeet somethingβ energy.
π NAME π
DROP_COLLATION β remove a collation. Thatβs the whole mission, bestie: a previously defined collation is getting removed. π«Ά
β¨ SYNOPSIS β¨
DROP COLLATION [ IF EXISTS ] name [ CASCADE | RESTRICT ]
π¦ DESCRIPTION π¦
DROP COLLATION removes a previously defined collation. To be able to drop a collation, you must own the collation. No ownership, no drop β thatβs the rule. π
π PARAMETERS π
IF EXISTSβ do not throw an error if the collation does not exist. A notice is issued in this case. So itβs like, missing-collation chill mode. β¨nameβ the name of the collation. The collation name can be schema-qualified. Slay, qualified names are valid. πCASCADEβ automatically drop objects that depend on the collation, and in turn all objects that depend on those objects (see Section 5.15). Itβs giving domino effect, bestie. π₯RESTRICTβ refuse to drop the collation if any objects depend on it. This is the default. So if you donβt say anything, this is what you get. π
πΈ EXAMPLES πΈ
To drop the collation named german:
DROP COLLATION german;
Thatβs it. Iconic, simple, done. π
π₯ COMPATIBILITY π₯
The DROP COLLATION command conforms to the SQL standard, apart from the IF EXISTS option, which is a PostgreSQL extension. So thatβs the PostgreSQL-specific little extra, iykyk. π«
π SEE ALSO π
ALTER COLLATION(ALTER_COLLATION(7))CREATE COLLATION(CREATE_COLLATION(7))
Go read these next, bestie β theyβre the collation cinematic universe. π
This page was brought to you by PostgreSQL 17.11, dated 2026. Stay collated, bestie πβ¨π«Ά
π¦ where this page comes from
- opensuse-leap 16.0: postgresql17 17.11-160000.1.1 Β· PostgreSQL
- opensuse-leap 16.0: postgresql17 17.11-160000.1.1 Β· PostgreSQL
- opensuse-leap 16.0: postgresql17 17.11-160000.1.1 Β· PostgreSQL
- opensuse-leap 16.0: postgresql17 17.11-160000.1.1 Β· PostgreSQL
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms