delete from
contact_extend_options
where
extend_id = :extend_id
insert into contact_extend_options (extend_id,var_name,pretty_name,subquery,description,aggregated_p)
values (:extend_id,:var_name,:pretty_name,:subquery,:description,:aggregated_p)
update contact_extend_options
set var_name = :var_name,
pretty_name = :pretty_name,
subquery = :subquery,
description = :description,
aggregated_p = :aggregated_p
where extend_id = :extend_id
select
1
from
contact_extend_options
where
var_name = :var_name
select
pretty_name,
extend_id
from
contact_extend_options
$extra_query
select
var_name,
pretty_name,
subquery,
description
from
contact_extend_options
where
extend_id = :extend_id