--
-- news__archive/2
--
create or replace function news__archive(
  p_item_id integer,
  p_archive_date timestamp with time zone DEFAULT now()
) returns int4 as $$

DECLARE
BEGIN
    update cr_news
    set    archive_date = p_archive_date
    where  news_id = content_item__get_live_revision(p_item_id);

    return 0;
END;
$$ language plpgsql;