civisanalytics / civis-python

Civis API Python Client
BSD 3-Clause "New" or "Revised" License
34 stars 26 forks source link

[APIC-313] retain specific sql types in civis_file_to_table #402

Closed mheilman closed 4 years ago

mheilman commented 4 years ago

In the civis.io.civis_file_to_table function, the Python API client appears to tell platform to change SQL types like VARCHAR(1) in the table_columns argument to more generic values like VARCHAR(1024) when there are multiple files. The behavior seems reasonable when data types are automatically inferred (i.e., when need_table_columns is true), as noted in the code comment, but if the user has specified a dtype with specific length like VARCHAR(1), the import should just use that.

mheilman commented 4 years ago

@mheilman looks like the build errored

🤦 sorry about that. Fixed now