[PATCH] explain sortorder

From: "Timmer, Marius" <marius(dot)timmer(at)uni-muenster(dot)de>
To: pgsql-hackerspostgresqlorg <pgsql-hackers(at)postgresql(dot)org>
Subject: [PATCH] explain sortorder
Date: 2014-11-25 13:03:23
Message-ID: F4FF595C-D39D-4036-A446-57C91ABE6B31@exchange.wwu.de
Views: Raw Message | Whole Thread | Download mbox
Thread:
Lists: pgsql-hackers

Hello everyone,

For creating indexes on more than one column, it is useful to know the sort
order of each sort key. So now, if you run EXPLAIN in VERBOSE mode, you get
the sort order information in the order the sort keys are displayed - Lukas

- This patch is meant for discussion
- It’s against the master branch
- The patch compiles successfully and one test (inherit) is affected
- There are no platform-specific items in this patch
- The patch, as described, enhances EXPLAIN VERBOSE. For an example, see
the regression test
- There is no TODO item referring to this patch

@patchname: explain_sortorder v2
@version: 2.01
@author: Marius Timmer <mtimm_01(at)uni-muenster(dot)de>,
Arne Scheffer <arne(dot)scheffer(at)uni-muenster(dot)de>,
Lukas Kreft <lukaskreft(at)uni-muenster(dot)de>
@description: Display sort order options in VERBOSE mode of EXPLAIN

- The situation

Currently I am able to run a EXPLAIN-Statement (verbose) for getting more
Information about a Query. But it is not enough to check in which order the
results will be sorted, what could be interesting to modify some Statements
so they can become more performant.

- What this patch does

This patch will add one more information to the result of an EXPLAIN-
Statement in verbose-mode. You will find the new property "Sort order"
which tells you the order of the used keys while sorting.
You can use it in all available Formats.

Greetings,

Marius Timmer

Attachment Content-Type Size
explain_sortorder-v2.patch application/octet-stream 15.3 KB
unknown_filename text/plain 142 bytes
smime.p7s application/pkcs7-signature 4.7 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2014-11-25 13:23:31 Re: Missing OOM checks in libpq (was Re: Replication connection URI?)
Previous Message Fujii Masao 2014-11-25 12:53:10 Re: The problems of PQhost()