[open-ils-commits] r14371 - trunk/Open-ILS/src/sql/Pg (miker)

svn at svn.open-ils.org svn at svn.open-ils.org
Mon Oct 12 12:41:37 EDT 2009


Author: miker
Date: 2009-10-12 12:41:34 -0400 (Mon, 12 Oct 2009)
New Revision: 14371

Modified:
   trunk/Open-ILS/src/sql/Pg/002.schema.config.sql
Log:
rolling back a portion of the last commit -- unintended

Modified: trunk/Open-ILS/src/sql/Pg/002.schema.config.sql
===================================================================
--- trunk/Open-ILS/src/sql/Pg/002.schema.config.sql	2009-10-12 16:37:22 UTC (rev 14370)
+++ trunk/Open-ILS/src/sql/Pg/002.schema.config.sql	2009-10-12 16:41:34 UTC (rev 14371)
@@ -562,38 +562,5 @@
       ( datatype <> 'link' AND fm_class IS NULL ) )
 );
 
-
--- Some handy functions, based on existing ones, to provide optional ingest normalization
-
-CREATE OR REPLACE FUNCTION public.left_trunc( TEXT, INT ) RETURNS TEXT AS $func$
-        SELECT SUBSTRING($1,$2);
-$func$ LANGUAGE SQL STRICT IMMUTABLE;
-
-CREATE OR REPLACE FUNCTION public.right_trunc( TEXT, INT ) RETURNS TEXT AS $func$
-        SELECT SUBSTRING($1,1,$2);
-$func$ LANGUAGE SQL STRICT IMMUTABLE;
-
-CREATE OR REPLACE FUNCTION public.split_date_range( TEXT ) RETURNS TEXT AS $func$
-        SELECT REGEXP_REPLACE( $1, E'(\\d{4})-(\\d{4})', E'\\1 \\2', 'g' );
-$func$ LANGUAGE SQL STRICT IMMUTABLE;
-
--- And ... a table in which to register them
-
-CREATE TABLE config.index_normalizer (
-        id              SERIAL  PRIMARY KEY,
-        name            TEXT    UNIQUE NOT NULL,
-        func            TEXT    NOT NULL,
-        param_count     INT     NOT NULL DEFAULT 0
-);
-
-CREATE TABLE config.metabib_field_index_norm_map (
-        id      SERIAL  PRIMARY KEY,
-        field   INT     NOT NULL REFERENCES config.metabib_field (id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
-        norm    INT     NOT NULL REFERENCES config.index_normalizer (id) ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED,
-        params  TEXT,
-        pos     INT     NOT NULL DEFAULT 0
-);
-
-
 COMMIT;
 



More information about the open-ils-commits mailing list