[OPEN-ILS-GENERAL] Problem of importing Gutenberg records

Jason Etheridge jason at esilibrary.com
Fri Dec 4 09:00:47 EST 2009


> psql:/root/gutenberg.sql:16: ERROR:  trigger
> "zzz_update_materialized_simple_record_tgr" for table "real_full_rec" does
> not exist
> CONTEXT:  SQL function "disable_materialized_simple_record_trigger"
> statement 1

Hi Araik,

So this is your first error, and you can ignore the ones that follow it.

It looks like we were moving away from
zzz_update_materialized_simple_record_tgr in 1.6.

This is the 1.6.0.0 definition of disable_materialized_simple_record_trigger:

CREATE OR REPLACE FUNCTION
reporter.disable_materialized_simple_record_trigger () RETURNS VOID AS
$$
    DROP TRIGGER zzz_update_materialized_simple_record_tgr ON
metabib.real_full_rec;
$$ LANGUAGE SQL;

Try running this in psql to replace it with the version from the rel_1_6 branch:

CREATE OR REPLACE FUNCTION
reporter.disable_materialized_simple_record_trigger () RETURNS VOID AS
$$
    DECLARE x RECORD;
    BEGIN
        -- DROP TRIGGER IF EXISTS is only available starting with PostgreSQL 8.2
        FOR x IN SELECT tgname FROM pg_trigger WHERE tgname =
'zzz_update_materialized_simple_record_tgr'
        LOOP
            DROP TRIGGER zzz_update_materialized_simple_record_tgr ON
metabib.real_full_rec;
        END LOOP;
    END;
$$ LANGUAGE plpgsql;

And then see if things work better.  Re-run the first SQL if that
doesn't help or other folks chime in saying I'm crazy. :)

-- 
Jason Etheridge
 | VP, Tactical Development
 | Equinox Software, Inc. / The Evergreen Experts
 | phone:  1-877-OPEN-ILS (673-6457)
 | email:  jason at esilibrary.com
 | web:  http://www.esilibrary.com

Please join us for the Evergreen 2010 International Conference, April 20-23,
2010 at the Amway Grand Hotel and Convention Center, Grand Rapids, Michigan.
http://www.evergreen2010.org/


More information about the Open-ils-general mailing list