uri
DTDrizzle Team
•Created by uri on 3/6/2025 in #help
Best practises for handling postresql errors?
Race conditions are always tricky. In my case there will be very few concurrent users modifying this data, the data is not critical, and I check and the update in the same transaction. Despite all this I appreciate any other insight on this issue.
It would be nice if I could execute a method in .onConflict , I don't want to do anything in the database when a conflict occurs, I just want to warn the user. So my doubts are whether is better lo let postgresql complain and catch the error, make all checking by myself as I'm already doing, or exploring if there exists a better way with drizzle to handle conflicts and warn the frontend user.
6 replies
DTDrizzle Team
•Created by uri on 3/4/2025 in #help
How should I refactor my transactions?
yup, I don't like it either... ☹️
3 replies