public static function get_recordset_for_due_and_incomplete() {
        global $DB;
        $sql = "duedate > 0 AND duedate < :now AND status = :status";
        $params = array('now' => time(), 'status' => self::STATUS_ACTIVE);
        return $DB->get_recordset_select(self::TABLE, $sql, $params);
    }