oracle8.1.6 select item_id, nvl(content_item.get_title(item_id),name) title, content_item.get_path(item_id) path, pretty_name as content_type_pretty, content_symlink.is_symlink(item_id) is_symlink, content_folder.is_folder(item_id) is_folder, content_template.is_template(item_id) is_template from cr_items i, acs_object_types t where i.content_type = t.object_type and item_id in ([join $clip_items ","]) and -- permissions check cms_permission.permission_p( item_id, :user_id, 'cm_write' ) = 't' order by -- this way parents are deleted after their children item_id desc begin $delete_proc ( $delete_key => :del_item_id ); end; content_symlink.delete content_folder.delete content_template.delete content_item.delete