Databaseerror: Current Transaction Is Aborted, Commands Ignored Until End of Transaction Block

DatabaseError: current transaction is aborted, commands ignored until end of transaction block?

This is what postgres does when a query produces an error and you try to run another query without first rolling back the transaction. (You might think of it as a safety feature, to keep you from corrupting your data.)

To fix this, you'll want to figure out where in the code that bad query is being executed. It might be helpful to use the log_statement and log_min_error_statement options in your postgresql server.

Django+Postgres: current transaction is aborted, commands ignored until end of transaction block

You can try this:

from django.db import connection
connection._rollback()

The more detailed discussion of This issue can be found here

ERROR: current transaction is aborted, commands ignored until end of transaction block --- export data from Aqua studio

You probably shouldn't be exporting millions of rows through a JDBC/ODBC connection, especially for Redshift.

For Redshift, please use the UNLOAD command documented here. You'll have to UNLOAD the file to S3 and download it from there.

For Postgres, use COPY TO as documented here.



Related Topics



Leave a reply



Submit