Hello,
My table has primary key constraint on a perticular column, Im loosing primary key constaint on that column each time I overwrite the table , What Can I do to preserve it? Any Heads up would be appreciated
Tried Below
df.write.option("truncate", "true").jdbc(url=DATABASE_URL, table=DATABASE_TABLE, mode="overwrite", properties=DATABASE_PROPERTIES)
But It errored out as below when a new column was added to dataframe which was not there in table
AnalysisException: Column "new_col" not found in schema Some