Sequences in DB/pgsql (once again)
| From: | Alexey Borzov | Date: | Thu, 14 Dec 2000 09:12:47 +0000 |
| Subject: | Sequences in DB/pgsql (once again) | ||
| Groups: | php.pear | ||
| Request: | Send a blank email to php-pear+get-691@lists.php.net to get a copy of this message | ||
Greetings!
Well, I made an update of PEAR and found sequence implementation...
First of all, I honestly don't think that
if ($ondemand && DB::isError($result) &&
$result->getMessage() == "DB Error: ERROR: db_seq_test.nextval: sequence does not
exist\n") {
is the intended behaviour... ;]
Relying on error messages' format is probably a Bad Thing itself...
As for 'db_seq_{$seq_name}' - I don't think that prepending *anything* to
table (or sequence) name is good. The reasons are simple -
prefixes are usually used for hiding something or grouping (if a table
name begins with 'pg_' in Postgres - it is a system table, if it
begins with 'pga_' - it is a PgAccess table and is not shown in
PgAccess). Besides, 'db_' prefix is misleading.
--
Yours, Alexey V. Borzov, Webmaster of RDW