Sha256: 5f928325c022d16e90ecb97b5a65a1593ea486df969d55e291572b0401695154

Contents?: true

Size: 522 Bytes

Versions: 56

Compression:

Stored size: 522 Bytes

Contents

/* Queries that have longest execution time in aggregate */

SELECT interval '1 millisecond' * total_exec_time AS total_exec_time,
to_char((total_exec_time/sum(total_exec_time) OVER()) * 100, 'FM90D0') || '%%'  AS prop_exec_time,
to_char(calls, 'FM999G999G999G990') AS ncalls,
interval '1 millisecond' * (blk_read_time + blk_write_time) AS sync_io_time,
query AS query
FROM pg_stat_statements WHERE userid = (SELECT usesysid FROM pg_user WHERE usename = current_user LIMIT 1)
ORDER BY total_exec_time DESC
LIMIT %{limit};

Version data entries

56 entries across 56 versions & 1 rubygems

Version Path
ruby-pg-extras-5.5.1 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.5.0 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.4.5 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.4.4 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.4.3 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.4.2 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.4.1 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.4.0 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.3.1 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.3.0 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.2.5 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.2.4 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.2.3 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.2.2 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.2.1 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.2.0 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.1.0 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-5.0.0 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-4.13.0 lib/ruby_pg_extras/queries/outliers.sql
ruby-pg-extras-4.12.2 lib/ruby_pg_extras/queries/outliers.sql