is their any method to ignore errors in postgresql ?? when we are moving csv file to postgresql database if any row has bad data whole copy is stopped is their any way we can skip the error row and copy all the good rows to database.
Hi, it's easy. Run a for loop on each CSV row and use a try-except inside each iteration. Then only correct rows will be inserted and errors can be ignored Hope this helps, cheers 👍
@@learningsoftwareskills i have tried but it is not working I have read in few forms that if their is error in any row of CSV file than that CSV file will not be move to postgresql
stackoverflow.com/a/5500831/2746323 Hi, the issue you have faced is addressed in this stack overflow post. Please add the additional host parameter as shown in this solution and check Hope this helps, Cheers 👍
Hi, please provide the details about the issues you faced to use psycopg2. We can try to resolve. Please check the port number you are using in your code (Mostly it will be 5432). You can also mail to learningsoftwareskils@gmail.com.
is their any method to ignore errors in postgresql ?? when we are moving csv file to postgresql database if any row has bad data whole copy is stopped is their any way we can skip the error row and copy all the good rows to database.
Hi, it's easy. Run a for loop on each CSV row and use a try-except inside each iteration. Then only correct rows will be inserted and errors can be ignored
Hope this helps, cheers 👍
@@learningsoftwareskills i have tried but it is not working I have read in few forms that if their is error in any row of CSV file than that CSV file will not be move to postgresql
Awsome!
Thanks for the amazing feedback 👍
How to connect using SSH, private key (.pem) and Jump server details?
Hi, I think this link has the code you require
gist.github.com/deehzee/53c8708417312e5deb32c58b73dca7a5
Hope this helps, cheers 👍
the reason why i'm here is that error:
psycopg2.OperationalError.
Can you help me ?
stackoverflow.com/a/5500831/2746323
Hi, the issue you have faced is addressed in this stack overflow post.
Please add the additional host parameter as shown in this solution and check
Hope this helps, Cheers 👍
it does not work at all
Hi, please provide the details about the issues you faced to use psycopg2. We can try to resolve.
Please check the port number you are using in your code (Mostly it will be 5432).
You can also mail to learningsoftwareskils@gmail.com.