- let sth = dbh#prepare_cached "update contacts set name = ?, subject = ?
- where hostid = ? and id = ?" in
- sth#execute [`String name; `String subject; `Int hostid; `Int id];
-
- let sth =
- dbh#prepare_cached "delete from contact_emails where contactid = ?" in
- sth#execute [`Int id];
+ PGSQL(dbh) "update contacts set name = $name, subject = $subject
+ where hostid = $hostid and id = $id";
+ PGSQL(dbh) "delete from contact_emails where contactid = $id";