1998-06-16 15:07:11 +08:00
|
|
|
--
|
2005-06-23 08:06:37 +08:00
|
|
|
-- PostgreSQL code for managed Large Objects
|
1998-06-16 15:07:11 +08:00
|
|
|
--
|
2005-06-23 08:06:37 +08:00
|
|
|
-- $PostgreSQL: pgsql/contrib/lo/lo.sql.in,v 1.13 2005/06/23 00:06:37 tgl Exp $
|
1998-06-16 15:07:11 +08:00
|
|
|
--
|
|
|
|
|
2002-10-19 02:41:22 +08:00
|
|
|
-- Adjust this setting to control where the objects get created.
|
|
|
|
SET search_path = public;
|
|
|
|
|
2005-06-23 08:06:37 +08:00
|
|
|
--
|
|
|
|
-- Create the data type ... now just a domain over OID
|
|
|
|
--
|
1998-06-16 15:07:11 +08:00
|
|
|
|
2005-06-23 08:06:37 +08:00
|
|
|
CREATE DOMAIN lo AS pg_catalog.oid;
|
2000-11-22 05:51:58 +08:00
|
|
|
|
2005-06-23 08:06:37 +08:00
|
|
|
--
|
|
|
|
-- For backwards compatibility, define a function named lo_oid.
|
|
|
|
--
|
|
|
|
-- The other functions that formerly existed are not needed because
|
|
|
|
-- the implicit casts between a domain and its underlying type handle them.
|
|
|
|
--
|
|
|
|
CREATE FUNCTION lo_oid(lo) RETURNS pg_catalog.oid AS
|
|
|
|
'SELECT $1::pg_catalog.oid' LANGUAGE SQL STRICT IMMUTABLE;
|
1998-06-16 15:07:11 +08:00
|
|
|
|
|
|
|
-- This is used in triggers
|
2002-10-19 02:41:22 +08:00
|
|
|
CREATE FUNCTION lo_manage()
|
2005-06-23 08:06:37 +08:00
|
|
|
RETURNS pg_catalog.trigger
|
2002-10-19 02:41:22 +08:00
|
|
|
AS 'MODULE_PATHNAME'
|
2005-01-30 06:35:02 +08:00
|
|
|
LANGUAGE C;
|