Class: ArJdbc::SQLite3::ExplainSupport::ExplainPrettyPrinter
- Inherits:
-
Object
- Object
- ArJdbc::SQLite3::ExplainSupport::ExplainPrettyPrinter
- Defined in:
- lib/arjdbc/sqlite3/explain_support.rb
Overview
:nodoc:
Instance Method Summary collapse
-
#pp(result) ⇒ Object
Pretty prints the result of a EXPLAIN QUERY PLAN in a way that resembles the output of the SQLite shell:.
Instance Method Details
#pp(result) ⇒ Object
Pretty prints the result of a EXPLAIN QUERY PLAN in a way that resembles the output of the SQLite shell:
0|0|0|SEARCH TABLE users USING INTEGER PRIMARY KEY (rowid=?) (~1 rows) 0|1|1|SCAN TABLE posts (~100000 rows)
24 25 26 27 28 |
# File 'lib/arjdbc/sqlite3/explain_support.rb', line 24 def pp(result) result.rows.map do |row| row.join('|') end.join("\n") + "\n" end |