select count(*)
from lang_message_keys
where package_key = :package_key
and message_key = :message_key
insert into lang_messages ([join $col_clauses ", "])
values ([join $val_clauses ", "])
update lang_messages
set [join $set_clauses ", "]
where locale = :locale
and package_key = :package_key
and message_key = :message_key