$_ eq '*' # Yes, this means you can't have a column just called '*'.
? $_ # Yes, this is a feature. Go shoot the DBA if he disagrees.
: ( # reserved are stored uc, quote if non-word
- $always_quote || $res_check->{+uc} || /\W/
+ ($always_quote and $q1) || $res_check->{+uc} || /\W/
? $q1.$_.$q2
: $_
)