Index: openacs-4/packages/news/sql/postgresql/upgrade/upgrade-4.1.0b-4.6.sql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/news/sql/postgresql/upgrade/upgrade-4.1.0b-4.6.sql,v
diff -u -r1.2 -r1.3
--- openacs-4/packages/news/sql/postgresql/upgrade/upgrade-4.1.0b-4.6.sql	30 Nov 2002 17:38:58 -0000	1.2
+++ openacs-4/packages/news/sql/postgresql/upgrade/upgrade-4.1.0b-4.6.sql	27 Oct 2014 16:41:47 -0000	1.3
@@ -4,13 +4,22 @@
 
 -- new function news__clone
 
-create or replace function news__clone (integer, integer)
-returns integer as '
-declare
- p_new_package_id   alias for $1;   --default null,
- p_old_package_id   alias for $2;   --default null
+
+
+-- added
+select define_function_args('news__clone','new_package_id,old_package_id');
+
+--
+-- procedure news__clone/2
+--
+CREATE OR REPLACE FUNCTION news__clone(
+   p_new_package_id integer, --default null,
+   p_old_package_id integer  --default null
+
+) RETURNS integer AS $$
+DECLARE
  one_news		record;	 
-begin
+BEGIN
         for one_news in select
                             publish_date,
                             cr.content as text,
@@ -60,5 +69,6 @@
 
         end loop;
  return 0;
-end;
-' language 'plpgsql';
+END;
+
+$$ LANGUAGE plpgsql;
