A Batch insert With no exceptions, But return error list , Is it Available ? #1648
Replies: 1 comment
-
Please look at psycopg 3 features about prepared statements and pipeline mode. If the error you are talking about is a duplicate key you can use Solving it in a generic case, whatever you do you need to set up a transaction per statement, so it will be inevitably slow, even if you use prepared statements and server stored procedures. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I would like to know that below scenario can be achieved by psycopg2
I have a dictionary of data to batch insert to postgresdb.
i will pass the prepared statement and this data to psycopg2 batch function, along with some argument saying ,'i want to commit all succesfully inserted, and rollback which got error'
finally return the error list if exist
similar functionality was found in the oracle
Beta Was this translation helpful? Give feedback.
All reactions