Re: enforce naming convention - Mailing list pgsql-general

From SunWuKung
Subject Re: enforce naming convention
Date
Msg-id 1145283984.736324.292180@t31g2000cwb.googlegroups.com
Whole thread Raw
In response to Re: enforce naming convention  ("Greg Sabino Mullane" <greg@turnstep.com>)
Responses Re: enforce naming convention  (Martijn van Oosterhout <kleptog@svana.org>)
List pgsql-general
I know that one of the main reasons why schemas are there is to make it
possible to use identical table names, but this time they want to use
it to separate tables purely because they feel they would find their
ways better that way. On the other hand I feel that this separation
will be somewhat arbitrary and may change in the future - to make sure
that tables will be freely movable between schemas I want to make sure
that there will be no identical names.

This may be totally wronb, but what about writing a Before Insert
trigger on the pg_catalog.pg_class table checking if there is already a
table with that name and if yes prevent the insert?
Is there something against doing so?

Thanks for the help.
SWK


pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: hard shutdown of system
Next
From: Martijn van Oosterhout
Date:
Subject: Re: enforce naming convention