How to call pandas_to_vertica insert error
polakrish
Vertica Customer
In Table DDL, i am using varchar(20) for the column but the data from pandas is varchar(80) for the same column.
I am using pandas_to_vertica function for ingesting data.
How could i populate the below same error using verticapy.
Due to this records are getting dropped.
This error i see while running manual insert in vertica:
SQL Error [8682] [22001]: [Vertica]VJDBC ERROR: String of 61 octets is too long for type Varchar(20) for column name
Using similar code:
resp=pandas_to_vertica(df,
name = {table},
cursor = cur,
schema = "schema",
insert = True
)
print(resp)
Tagged:
0
Answers
@polakrish : Error message you are receiving is expected because the data length in pandas for that column is greater than varchar(20) defined for the table in vertica. please change the table def in vertica and try pandas_to_vertica again