DROP_COLLATION(7pg14)

πŸ“¦ version 14.24, in opensuse-leap 16.0

πŸ’… DROP COLLATION πŸ’…

okay so this is the DROP COLLATION page from the PostgreSQL 14.24 Documentation, and bestie, it's short, it's sweet, and it's about to make your collation shelf so much cleaner ✨


🌸 NAME 🌸

DROP_COLLATION β€” remove a collation, that's literally it, that's the whole vibe πŸŽ€


✨ SYNOPSIS ✨

DROP COLLATION [ IF EXISTS ] name [ CASCADE | RESTRICT ]

look at her. so clean. so composed. main character energy fr fr πŸ‘‘


πŸ¦‹ DESCRIPTION πŸ¦‹

okay so DROP COLLATION removes a previously defined collation. gone. deleted. not coming to the group chat anymore πŸ’€

but here's the thing β€” to be able to drop a collation, you must own the collation. no ownership, no dropping. them's the rules, no cap 🫢


πŸ’– PARAMETERS πŸ’–

  • IF EXISTS β€” do not throw an error if the collation does not exist. instead, a notice is issued in this case. very polite, very demure, very "no drama" of her πŸ™ˆ
  • name β€” the name of the collation. and yes, the collation name can be schema-qualified. go off with your dots πŸŽ€
  • CASCADE β€” automatically drop objects that depend on the collation, and in turn all objects that depend on those objects (see Section 5.14). it's giving domino effect, it's giving "and YOU get dropped, and YOU get dropped" πŸ’€πŸ’…
  • RESTRICT β€” refuse to drop the collation if any objects depend on it. this is the default. she's the cautious one. she's the responsible friend. we love her for it 🫢

🌈 EXAMPLES 🌈

to drop the collation named german:

DROP COLLATION german;

that's it. that's the whole example. iconic, honestly πŸ‘‘


⭐ COMPATIBILITY ⭐

the DROP COLLATION command conforms to the SQL standard, apart from the IF EXISTS option, which is a PostgreSQL extension. so she's standard-compliant but with a lil extra sparkle, iykyk ✨


πŸŽ€ SEE ALSO πŸŽ€

go read those too bestie, the whole collation cinematic universe is waiting πŸ¦‹


lowkey reminder: no ownership = no drop. don't come for collations that aren't yours, queen πŸ’…

slay, you now understand DROP COLLATION πŸ§šπŸ’œ

β€” xoxo, brought to you by PostgreSQL 14.24, dated 2026, and the icon herself, DROP COLLATION(7) πŸ“πŸ‘‘

πŸ“¦ where this page comes from