diff options
Diffstat (limited to 'src/bin/psql/common.c')
-rw-r--r-- | src/bin/psql/common.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/bin/psql/common.c b/src/bin/psql/common.c index 00627830c47..f907f5d4e8d 100644 --- a/src/bin/psql/common.c +++ b/src/bin/psql/common.c @@ -1276,6 +1276,8 @@ DescribeQuery(const char *query, double *elapsed_msec) if (timing) INSTR_TIME_SET_CURRENT(before); + else + INSTR_TIME_SET_ZERO(before); /* * To parse the query but not execute it, we prepare it, using the unnamed @@ -1406,6 +1408,8 @@ ExecQueryAndProcessResults(const char *query, if (timing) INSTR_TIME_SET_CURRENT(before); + else + INSTR_TIME_SET_ZERO(before); if (pset.bind_flag) success = PQsendQueryParams(pset.db, query, pset.bind_nparams, NULL, (const char * const *) pset.bind_params, NULL, NULL, 0); @@ -1702,6 +1706,8 @@ ExecQueryUsingCursor(const char *query, double *elapsed_msec) if (timing) INSTR_TIME_SET_CURRENT(before); + else + INSTR_TIME_SET_ZERO(before); /* if we're not in a transaction, start one */ if (PQtransactionStatus(pset.db) == PQTRANS_IDLE) |