Index: modules/og_notifications/og_notifications.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/og/modules/og_notifications/og_notifications.module,v
retrieving revision 1.16
diff -u -r1.16 og_notifications.module
--- modules/og_notifications/og_notifications.module	4 Nov 2008 18:25:51 -0000	1.16
+++ modules/og_notifications/og_notifications.module	27 Jan 2009 00:56:43 -0000
@@ -258,9 +258,8 @@
         $query = array();
         if (isset($node->og_groups)) {
           $query[] = array(
-            'join' => "LEFT JOIN {og_ancestry} oga ON f.field = 'group' AND f.value = CAST(oga.group_nid AS CHAR(255))",
-            'where' => 'oga.nid = %d',
-            'args' => array($node->nid)
+            'join' => "LEFT JOIN {og_ancestry} oga ON oga.nid = %d AND f.field = 'group' AND f.intval = oga.group_nid",
+            'join args' => array($node->nid),
           );
         }
         if ($arg0 == 'user' && og_is_group_type($node->type)) {
