From: | Bogdan Pilch <bogdan(at)matfyz(dot)cz> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Time measurement format - more human readable |
Date: | 2014-09-28 11:49:51 |
Message-ID: | 20140928114951.GB22150@artax.karlin.mff.cuni.cz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
I have created a small patch to postgres source (in particular the
psql part of it) that modifies the way time spent executing the SQL
commands is printed out.
The idea is to have a human readable time printed, e.g.:
Time: 1:32:15.45 m:s:ms
Time: 2_10:12:55:444.033 d_h:m:s:ms
Attached you can find a patch without any regression tests for that as
this is practically impossible to test with regression tests. The
duration of an SQL command (even though using pg_sleep) would differ
on each machine and even between consecutive runs. Therefore one
cannot specify a static expected output.
My patch is relative to origin/REL9_4_STABLE branch as that is the one
I started from.
My plea is to have this change merged into the main stream so that it
becomes available in upcoming releases.
This modification does not require any interaction with user.
It may create backward compatibility issues if some SQL developers
assumed that the format is always <milis>.<micros>.
regards
bogdan
Attachment | Content-Type | Size |
---|---|---|
0002-time_measurement_format.patch | text/x-diff | 2.7 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Bogdan Pilch | 2014-09-28 11:56:15 | Tab expansion - on/off feature |
Previous Message | Bogdan Pilch | 2014-09-28 11:42:46 | Trailing comma support in SELECT statements |