问题
I am getting this error message (shown in title), when I run this SQL statement in PG 8.4:
psql -h localhost -U postgres -d mydb -c "CREATE TRUSTED PROCEDURAL LANGUAGE 'plpgsql' HANDLER plpgsql_call_handler VALIDATOR plpgsql_validator"
What's causing this (it used to work with earlier versions of PG), and how do I resolve it?
回答1:
This procedure has been simplified. For plpgsql simply use:
CREATE LANGUAGE plpgsql;
The error message tells you, that plpgsql is among a number of predefined languages listed in the system table pg_pltemplate. Just have a look:
SELECT * FROM pg_pltemplate;
In PostgreSQL 9.0 and later, PL/pgSQL is pre-installed by default.
来源:https://stackoverflow.com/questions/8680870/notice-using-pg-pltemplate-information-instead-of-create-language-parameters