def get_col_index(col_name, col_defs):
    """
    Get index of column for a column name in a table.

    :type col_name: str
    :param col_name: Column name to get column definition for
    :type col_defs: list[dict]
    :param col_defs: Column definitions for table
    :rtype: int
    :return: Index of column. None if not found.
    """

    return next(iter([i for i in range(len(col_defs)) if col_defs[i]['name'] == col_name]), None)