November 2019
Beginner to intermediate
470 pages
11h 59m
English
Now that we've discussed the first couple of views, it's time to turn our attention to one of the most important views, which can be used to spot performance problems. I am, of course, speaking about pg_stat_statements. The idea is to have information about queries on your system. It helps us figure out which types of queries are slow and how often queries are called.
To use this module, we need to follow three steps:
Let's inspect the definition of the view:
test=# \d pg_stat_statements View "public.pg_stat_statements" Column | Type ...