def METHOD_NAME(self, sent='N'):
    """
    Get users which has messages with given sent status (normally unsent).
    Returns a sorted list with the phone numbers for all users with
    messages with given sent status.
    """
    users = []
    dbconn = self._connect()
    db = dbconn.cursor()
    data = dict(sent=sent)
    sql = """SELECT DISTINCT phone
        FROM smsq
        WHERE sent = %(sent)s
        ORDER BY phone"""
    db.execute(sql, data)
    result = db.fetchall()
    # Rollback so we don't have old open transactions which foobars the
    # usage of now() in setsentstatus()
    dbconn.rollback()
    # Create a simple list without the tuples
    for row in result:
        users.append(row[0])
    return users