postgresql7.3
select p.process_id, p.title, o.creation_user,
person__name(o.creation_user) as creator_name, p.description,
to_char(o.creation_date, 'YYYY-MM-DD') as creation_date_ansi,
(select count(*)
from t_process_instances pi
where pi.process_id = p.process_id) as instances
from t_processes p, acs_objects o
where p.process_id = o.object_id
and p.workflow_id is not null
and o.package_id = :package_id
order by lower(p.title)