You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using powa on a moderately complex database with several schemas and search_path set appropriately for all users.
However, requests are stored by powa without full specification and powa-web cannot analyze SOME queries. That's another mystery, for some are analyzed.
What could be wrong?
The text was updated successfully, but these errors were encountered:
There are multiple reasons that could explain a failure in getting this kind of error.
First of all, powa gets the data (which here is the normalized query text) from pg_stat_statements, and that extensions normalize the query string as-is, without trying to fully qualify object or store the associated search_path at the time the query text is stored. This has already been discussed in the past (see for instance https://www.postgresql.org/message-id/flat/9baf5c06-d6ab-c688-010c-843348e3d98c%40gmail.com for the last one I remember), but unfortunately none of the committer is interested in that topic nothing was ever done.
Note also that pg_stat_statements stores the first query string associated to an entry, so if you sometime use the search_path and sometime rely on fully qualified objects for the exact same queryid, you may or may not get a useful entry.
Since the error is relation "core_departurecalculationtask" does not exist, I'm assuming that either that table does not exist anymore (maybe a temporary table or a table dropped since), or more likely it was stored by pg_stat_statements using a non default search_path.
Maybe it works for some other queries because the saved query text was qualified, or because there's a matching relation relation name (not necessarily the same object as the one in the query though) in the connection default search_path.
Unfortunately there isn't much we can do without change in pg_stat_statements. The only possibility on the powa side would be to let users manually tag the queries with a search_path, but it looks like a lot of error-prone work for users.
Hello
I'm using powa on a moderately complex database with several schemas and search_path set appropriately for all users.
However, requests are stored by powa without full specification and powa-web cannot analyze SOME queries. That's another mystery, for some are analyzed.
What could be wrong?
The text was updated successfully, but these errors were encountered: