Index: openacs-4/packages/faq-portlet/sql/postgresql/faq-portlet-drop.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/faq-portlet/sql/postgresql/faq-portlet-drop.sql,v diff -u -N -r1.2 -r1.3 --- openacs-4/packages/faq-portlet/sql/postgresql/faq-portlet-drop.sql 9 Aug 2002 18:39:31 -0000 1.2 +++ openacs-4/packages/faq-portlet/sql/postgresql/faq-portlet-drop.sql 27 Oct 2014 16:41:30 -0000 1.3 @@ -34,21 +34,27 @@ -- 29 June 2002 -create function inline_0 () -returns integer as ' -declare + + +-- +-- procedure inline_0/0 +-- +CREATE OR REPLACE FUNCTION inline_0( + +) RETURNS integer AS $$ +DECLARE ds_id portal_datasources.datasource_id%TYPE; -begin +BEGIN select datasource_id into ds_id from portal_datasources - where name = ''faq_portlet''; + where name = 'faq_portlet'; -- Exception handling? if not found then - raise notice ''No datasource_id found here '', ds_id ; + raise notice 'No datasource_id found here ', ds_id ; ds_id := null; end if; @@ -59,7 +65,8 @@ return 0; -end;' language 'plpgsql'; +END; +$$ LANGUAGE plpgsql; select inline_0 ();