def row2dict(row):
    """Converts SQLAlchemy row to dict

    Args:
        row: A SQLAlchemy query result object

    Returns
        dict: Returns the row as dictionary

    """
    d = {}
    for column in row.__table__.columns:
        d[column.name] = str(getattr(row, column.name))
    return d
