def __getColTypesDict__(conn,tbl_schema,tbl_nm):
    col_types_stmt = ''' 
                        select column_name, data_type
                        from information_schema.columns 
                        where table_schema = '{table_schema}' and table_name = '{table_name}';
                     '''.format(table_schema=tbl_schema, table_name = tbl_nm)
                       
    result = psql.read_frame(col_types_stmt, conn.getConnection())
    col_types_dict = dict(zip(result.get('column_name'),result.get('data_type')))
    return col_types_dict
Return a dict containing column names and their type, by querying the information schema
dataset/ETHPy150Open pivotalsoftware/pymadlib/pymadlib/utils.py/__getColTypesDict__