[open-ils-commits] r10238 - branches/rel_1_2/Open-ILS/src/sql/Pg
svn at svn.open-ils.org
svn at svn.open-ils.org
Sat Aug 2 10:53:38 EDT 2008
Author: miker
Date: 2008-08-02 10:53:20 -0400 (Sat, 02 Aug 2008)
New Revision: 10238
Modified:
branches/rel_1_2/Open-ILS/src/sql/Pg/010.schema.biblio.sql
Log:
set a reasonable prefix on autogenerated TCN values
Modified: branches/rel_1_2/Open-ILS/src/sql/Pg/010.schema.biblio.sql
===================================================================
--- branches/rel_1_2/Open-ILS/src/sql/Pg/010.schema.biblio.sql 2008-08-01 18:57:44 UTC (rev 10237)
+++ branches/rel_1_2/Open-ILS/src/sql/Pg/010.schema.biblio.sql 2008-08-02 14:53:20 UTC (rev 10238)
@@ -21,8 +21,8 @@
CREATE SCHEMA biblio;
CREATE SEQUENCE biblio.autogen_tcn_value_seq;
-CREATE FUNCTION biblio.next_autogen_tcn_value () RETURNS TEXT AS $$
- BEGIN RETURN nextval('biblio.autogen_tcn_value_seq'::TEXT); END;
+CREATE OR REPLACE FUNCTION biblio.next_autogen_tcn_value () RETURNS TEXT AS $$
+ BEGIN RETURN 'AUTOGENERATED-' || nextval('biblio.autogen_tcn_value_seq'::TEXT); END;
$$ LANGUAGE PLPGSQL;
CREATE TABLE biblio.record_entry (
More information about the open-ils-commits
mailing list