diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2002-09-19 22:48:34 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2002-09-19 22:48:34 +0000 |
commit | 4a0c3a6142698c7f2f99230679dc80cd9d7e5e4e (patch) | |
tree | 72bb97d89923372cd2a2b4a22b76365019bde611 /src/backend/commands/explain.c | |
parent | b26dfb95222fddd25322bdddf3a5a58d3392d8b1 (diff) | |
download | postgresql-4a0c3a6142698c7f2f99230679dc80cd9d7e5e4e.tar.gz postgresql-4a0c3a6142698c7f2f99230679dc80cd9d7e5e4e.zip |
Department of second thoughts: suppressing implicit casts everywhere in
ruleutils display is not such a great idea. For arguments of functions
and operators I think we'd better keep the historical behavior of showing
such casts explicitly, to ensure that the function/operator is reparsed
the same way when the rule is reloaded. This also makes the output of
EXPLAIN less obscurantist about exactly what's happening.
Diffstat (limited to 'src/backend/commands/explain.c')
-rw-r--r-- | src/backend/commands/explain.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/backend/commands/explain.c b/src/backend/commands/explain.c index 4edc7184214..2478c4f769f 100644 --- a/src/backend/commands/explain.c +++ b/src/backend/commands/explain.c @@ -5,7 +5,7 @@ * Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group * Portions Copyright (c) 1994-5, Regents of the University of California * - * $Header: /cvsroot/pgsql/src/backend/commands/explain.c,v 1.87 2002/09/04 20:31:15 momjian Exp $ + * $Header: /cvsroot/pgsql/src/backend/commands/explain.c,v 1.88 2002/09/19 22:48:33 tgl Exp $ * */ @@ -682,7 +682,7 @@ show_scan_qual(List *qual, bool is_or_qual, const char *qlabel, NIL); /* Deparse the expression */ - exprstr = deparse_expression(node, context, (outercontext != NULL)); + exprstr = deparse_expression(node, context, (outercontext != NULL), false); /* And add to str */ for (i = 0; i < indent; i++) @@ -729,7 +729,7 @@ show_upper_qual(List *qual, const char *qlabel, /* Deparse the expression */ node = (Node *) make_ands_explicit(qual); - exprstr = deparse_expression(node, context, (inner_plan != NULL)); + exprstr = deparse_expression(node, context, (inner_plan != NULL), false); /* And add to str */ for (i = 0; i < indent; i++) @@ -795,8 +795,9 @@ show_sort_keys(List *tlist, int nkeys, const char *qlabel, if (target->resdom->reskey == keyno) { - /* Deparse the expression */ - exprstr = deparse_expression(target->expr, context, useprefix); + /* Deparse the expression, showing any top-level cast */ + exprstr = deparse_expression(target->expr, context, + useprefix, true); /* And add to str */ if (keyno > 1) appendStringInfo(str, ", "); |