Google sitemap.xml.
[cocanwiki.git] / scripts / contacts.ml
index 22adc38..9ba8e65 100644 (file)
@@ -1,7 +1,7 @@
 (* COCANWIKI - a wiki written in Objective CAML.
  * Written by Richard W.M. Jones <rich@merjis.com>.
  * Copyright (C) 2004 Merjis Ltd.
- * $Id: contacts.ml,v 1.1 2004/09/17 16:03:34 rich Exp $
+ * $Id: contacts.ml,v 1.2 2005/11/23 11:32:12 rich Exp $
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -33,7 +33,7 @@ let run r (q : cgi) (dbh : Dbi.connection) hostid _ _ =
   (* Pull out all the contacts from the database. *)
   let sth = dbh#prepare_cached
              "select c.id, c.name, c.subject,
-                      (select count(*) from contact_emails
+                      (select count(*)::int4 from contact_emails
                         where contactid = c.id)
                  from contacts c
                 where c.hostid = ?