Commit Graph

2 Commits (76b080214259067dfc3d9d2c350232ef1e234045)

Author SHA1 Message Date
Artem Gavrilov 76b0802142
PG-1313 Fix decode_error_level SQL function (#539)
Update decode_error_level funcion to support error codes up to PG
version 17.
2025-06-19 15:38:44 +02:00
Zsolt Parragi 61662cc58f
PG-1621: fix cmd_type mostly showing 0 values (#538)
This was actually caused by two bugs internally:

* cmd_type was only set in some codepaths, other parts of the code
never set a value. Depending on which query / how was executed,
it was possibly never changed (after a reset to 0)
* the update first set the cmd_type, then reset all counters. As
the cmd_type is stored within the counters for some reason, this
reset its value to 0 in most execution paths, even if it was corretly
set before.

And according to this the fix is simple:

* cmd_type is now set in all codepaths except for failing queries,
as we only have the error string in this case, without the type.
* in the update logic, we again overwrite cmd_type with the proper
value after a reset
2025-06-17 14:52:28 +01:00