From: Matt S Trout Date: Thu, 21 Mar 2013 03:20:49 +0000 (+0000) Subject: LimitXY Slice dialect X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=a2b858ee23fbb228c7e5487c20dff31e65766359;p=dbsrgits%2FData-Query.git LimitXY Slice dialect --- diff --git a/lib/Data/Query/Renderer/SQL/Slice/LimitXY.pm b/lib/Data/Query/Renderer/SQL/Slice/LimitXY.pm new file mode 100644 index 0000000..f1cf05b --- /dev/null +++ b/lib/Data/Query/Renderer/SQL/Slice/LimitXY.pm @@ -0,0 +1,20 @@ +package Data::Query::Renderer::SQL::Slice::LimitXY; + +use Moo::Role; + +sub slice_subquery { } + +sub slice_stability { } + +sub _render_slice { + my ($self, $dq) = @_; + [ ($dq->{from} ? $self->_render($dq->{from}) : ()), + $self->_format_keyword('LIMIT'), + ($dq->{offset} + ? ($self->_render($dq->{offset}), ',') + : ()), + $self->_render($dq->{limit}), + ]; +} + +1;