refactor: Pass relation OID instead of Relation to createForeignKeyCheckTriggers()

Peter Eisentraut <peter@eisentraut.org>

Commit: ef7a5af77d449ee2b426f627c1f7472740350040
Author: Peter Eisentraut <peter@eisentraut.org>
Date: 2025-03-25T16:04:12Z
Releases: 18.0
refactor: Pass relation OID instead of Relation to createForeignKeyCheckTriggers()

Currently, createForeignKeyCheckTriggers() takes a Relation type as
its first argument, but it doesn't use that argument directly.
Instead, it fetches the relation OID by calling RelationGetRelid().
Therefore, it would be more consistent with other functions (e.g.,
createForeignKeyCheckTriggers()) to pass the relation OID directly
instead of the whole Relation.

Author: Amul Sul <amul.sul@enterprisedb.com>
Discussion: https://www.postgresql.org/message-id/flat/CAAJ_b962c5AcYW9KUt_R_ER5qs3fUGbe4az-SP-vuwPS-w-AGA@mail.gmail.com

Files

PathChange+/−
src/backend/commands/tablecmds.c modified +6 −7

Discussion