Index: openacs-4/packages/new-portal/sql/postgresql/datasource-sc-drop.sql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/new-portal/sql/postgresql/datasource-sc-drop.sql,v
diff -u -r1.5 -r1.6
--- openacs-4/packages/new-portal/sql/postgresql/datasource-sc-drop.sql	9 Aug 2002 20:56:28 -0000	1.5
+++ openacs-4/packages/new-portal/sql/postgresql/datasource-sc-drop.sql	1 Nov 2013 21:45:33 -0000	1.6
@@ -21,116 +21,116 @@
 -- @version $Id$
 --
 
-create function inline_0 ()
-returns integer as '
-begin
+CREATE OR REPLACE FUNCTION inline_0 () RETURNS integer AS $$
+BEGIN
 
     -- drop GetMyName	  
     perform acs_sc_operation__delete(
-        ''portal_datasource'',
-        ''GetMyName''
+        'portal_datasource',
+        'GetMyName'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.GetMyName.InputType''
+        'portal_datasource.GetMyName.InputType'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.GetMyName.OutputType''
+        'portal_datasource.GetMyName.OutputType'
     );
 
     -- drop GetPrettyName		  
     perform acs_sc_operation__delete(
-        ''portal_datasource'',
-        ''GetPrettyName''
+        'portal_datasource',
+        'GetPrettyName'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.GetPrettyName.InputType''
+        'portal_datasource.GetPrettyName.InputType'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.GetPrettyName.OutputType''
+        'portal_datasource.GetPrettyName.OutputType'
     );
 
     -- drop Link
     perform acs_sc_operation__delete(
-        ''portal_datasource'',
-        ''Link''
+        'portal_datasource',
+        'Link'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.Link.InputType''
+        'portal_datasource.Link.InputType'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.Link.OutputType''
+        'portal_datasource.Link.OutputType'
     );
 
     -- Drop add_self_to_page	  
     perform acs_sc_operation__delete(
-        ''portal_datasource'',
-        ''AddSelfToPage''
+        'portal_datasource',
+        'AddSelfToPage'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.AddSelfToPage.InputType''
+        'portal_datasource.AddSelfToPage.InputType'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.AddSelfToPage.OutputType''
+        'portal_datasource.AddSelfToPage.OutputType'
     );
 
     -- Delete Show	  
     perform acs_sc_operation__delete(
-        ''portal_datasource'',
-        ''Show''
+        'portal_datasource',
+        'Show'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.Show.InputType''
+        'portal_datasource.Show.InputType'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.Show.OutputType''
+        'portal_datasource.Show.OutputType'
     );
 
     -- Delete Edit
     perform acs_sc_operation__delete(
-        ''portal_datasource'',
-        ''Edit''
+        'portal_datasource',
+        'Edit'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.Edit.InputType''
+        'portal_datasource.Edit.InputType'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.Edit.OutputType''
+        'portal_datasource.Edit.OutputType'
     );
 
     -- RemoveSelfFromPage
     perform acs_sc_operation__delete(
-        ''portal_datasource'',
-        ''RemoveSelfFromPage''
+        'portal_datasource',
+        'RemoveSelfFromPage'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.RemoveSelfFromPage.InputType''
+        'portal_datasource.RemoveSelfFromPage.InputType'
     );
 
     perform acs_sc_msg_type__delete(
-        ''portal_datasource.RemoveSelfFromPage.OutputType''
+        'portal_datasource.RemoveSelfFromPage.OutputType'
     );
 
     -- drop the contract 
     perform acs_sc_contract__delete(
-        ''portal_datasource''
+        'portal_datasource'
     );
 
     return 0;
 
-end;' language 'plpgsql';
+END;
+$$ LANGUAGE plpgsql;
 
 select inline_0();
 
