From: Matt S Trout Date: Sun, 29 Sep 2019 01:32:59 +0000 (+0000) Subject: murder more sqlcasing X-Git-Tag: v1.90_01~75 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=09570ab23498d4bafe309d0643278caae889400f;p=dbsrgits%2FSQL-Abstract.git murder more sqlcasing --- diff --git a/lib/SQL/Abstract.pm b/lib/SQL/Abstract.pm index 7545a3c..71d6204 100644 --- a/lib/SQL/Abstract.pm +++ b/lib/SQL/Abstract.pm @@ -1433,7 +1433,7 @@ sub _render_literal { sub _render_keyword { my ($self, undef, $keyword) = @_; - return [ $self->format_keyword($keyword) ]; + return [ $self->_sqlcase(join ' ', split '_', $keyword) ]; } sub _render_op { @@ -1521,7 +1521,7 @@ sub _render_op_multop { return $self->render_aqt($parts[0]) if @parts == 1; my $join = ($op eq ',' ? ', ' - : $self->format_keyword(" ${op} ") + : $self->_sqlcase(' '.(join ' ', split '_', $op).' ') ); return $self->join_query_parts($join, @parts); } @@ -1765,7 +1765,7 @@ sub _convert { #my ($self, $arg) = @_; if (my $conv = $_[0]->{convert_where}) { return @{ $_[0]->join_query_parts('', - $_[0]->format_keyword($conv), + $_[0]->_sqlcase($conv), '(' , $_[1] , ')' ) }; } @@ -1820,8 +1820,6 @@ sub _sqlcase { return $_[0]->{case} ? $_[1] : uc($_[1]); } -sub format_keyword { $_[0]->_sqlcase(join ' ', split '_', $_[1]) } - #====================================================================== # DISPATCHING FROM REFKIND #======================================================================