使用Postgresql的Rails 3 - 嘈杂的数据库?

时间:2010-11-03 21:17:03

标签: ruby-on-rails postgresql ruby-on-rails-3

我最近将我的Rails应用程序移动到Postgres,并在开发日志中注意到它充满了以下SQL语句:

  SQL (1.1ms)   SELECT a.attname, format_type(a.atttypid, a.atttypmod), d.adsrc, a.attnotnull
 FROM pg_attribute a LEFT JOIN pg_attrdef d
 ON a.attrelid = d.adrelid AND a.attnum = d.adnum
 WHERE a.attrelid = '"permissions"'::regclass
 AND a.attnum > 0 AND NOT a.attisdropped
 ORDER BY a.attnum
  SQL (1.1ms)   SELECT a.attname, format_type(a.atttypid, a.atttypmod), d.adsrc, a.attnotnull
 FROM pg_attribute a LEFT JOIN pg_attrdef d
 ON a.attrelid = d.adrelid AND a.attnum = d.adnum
 WHERE a.attrelid = '"spaces"'::regclass
 AND a.attnum > 0 AND NOT a.attisdropped
 ORDER BY a.attnum

任何人都知道这笔交易是什么,似乎是性能受损?是吗?

由于

1 个答案:

答案 0 :(得分:3)

您可以使用silent-postgres gem消除这些消息。