Here is the postgres version, can someone please put the oracle version into CVS ?
/openacs-4/packages/forums/sql/postgresql/upgrade/upgrade-1.2.0d3-1.3d1.sql
-- Update the package ids for projects
create function inline_0 ()
returns integer as '
declare
ct RECORD;
begin
for ct in select package_id, forum_id from forums_forums
loop
update acs_objects set package_id = ct.package_id where object_id = ct.forum_id;
end loop;
return null;
end;' language 'plpgsql';
select inline_0();
drop function inline_0();