From bb87fb0fac245efbcba383e1cc5255ffc5a2807e Mon Sep 17 00:00:00 2001 From: "patrick.benny" Date: Fri, 8 Jun 2012 14:36:35 +0900 Subject: [PATCH] The fix for double-quoting bug here: https://github.com/chipple/SQL-Abstract-Limit/commit/6ea6fbccf8ec22c4bb05bff9e697693bbfbe9154 ( Bug report: https://rt.cpan.org/Public/Bug/Display.html?id=34847 ) also made it possible to use $self->SUPER::select normally. Doing so would at the same time fix this bug: https://rt.cpan.org/Public/Bug/Display.html?id=50795 --- lib/SQL/Abstract/Limit.pm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/SQL/Abstract/Limit.pm b/lib/SQL/Abstract/Limit.pm index e7136b1..f61e571 100755 --- a/lib/SQL/Abstract/Limit.pm +++ b/lib/SQL/Abstract/Limit.pm @@ -162,9 +162,8 @@ sub select { $fields ||= '*'; # in case someone supplies '' or undef - # with no LIMIT parameters, defer to SQL::Abstract [ don't know why the first way fails ] - # return $self->SUPER::select( $table, $fields, $where, $order ) unless $rows; - return SQL::Abstract->new->select( $table, $fields, $where, $order ) unless $rows; + # with no LIMIT parameters, defer to SQL::Abstract + return $self->SUPER::select( $table, $fields, $where, $order ) unless $rows; # with LIMIT parameters, get the basic SQL without the ORDER BY clause my ( $sql, @bind ) = $self->SUPER::select( $table, $fields, $where );