17 ms·
Fair as well. It's just sending a command which you know will fail, and even relying on the fact it fails, feels wrong, whether it sends a request over network
by owl57 2y ago
Fair as well. It's just sending a command which you know will fail, and even relying on the fact it fails, feels wrong, whether it sends a request over network or not.
BTW I checked and it's not an error in Postgres, only a warning. Still not something I would want in my database logs for the happy path.
- randomdata 2y agoYou know it will fail if you didn't screw up anything else. But it's a good sanity check/safety measure to call it anyway incase you made a mistake elsewhere. An errant rollback is more likely to be caught in testing than a dangling transaction.