rendered paste bodymysql> select * from contextual;
+----+------+
| id | name |
+----+------+
| 1 | foo |
| 2 | bar |
| 3 | baz |
+----+------+
3 rows in set (0.00 sec)
mysql> select * from order_status;
+--------+----------------+
| blogid | pending_status |
+--------+----------------+
| 1 | 0 |
| 2 | 1 |
+--------+----------------+
2 rows in set (0.00 sec)
mysql> select * from contextual left outer join order_status on contextual.id=order_status.blogid and order_status.pending_status=0 where order_status.blogid is null;
+----+------+--------+----------------+
| id | name | blogid | pending_status |
+----+------+--------+----------------+
| 2 | bar | NULL | NULL |
| 3 | baz | NULL | NULL |
+----+------+--------+----------------+
2 rows in set (0.00 sec)