Fix psql \d commands to behave properly when a pattern using regex | is given.

Tom Lane <tgl@sss.pgh.pa.us>

Commit: 727517363673caec1f3a376f20862ab2e52fcec7
Author: Tom Lane <tgl@sss.pgh.pa.us>
Date: 2006-10-10T16:15:42Z
Releases: 7.3.16
Fix psql \d commands to behave properly when a pattern using regex | is given.
Formerly they'd emit '^foo|bar$' which is wrong because the anchors are
parsed as part of the alternatives; must emit '^(foo|bar)$' to get expected
behavior.  Same as bug found previously in similar_escape().  Already fixed
in HEAD, this is just back-porting the part of that patch that was a bug fix.

Files

PathChange+/−
src/bin/psql/describe.c modified +9 −19