From: Matt S Trout Date: Thu, 23 Aug 2012 18:27:21 +0000 (+0000) Subject: randomised crazy order by support for subquery remap X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=ce86e12ae0debba6da1babf94e5b269ee5a8b656;p=dbsrgits%2FData-Query.git randomised crazy order by support for subquery remap --- diff --git a/lib/Data/Query/Renderer/SQL/Slice/SubqueryRemap.pm b/lib/Data/Query/Renderer/SQL/Slice/SubqueryRemap.pm index 261088e..325084b 100644 --- a/lib/Data/Query/Renderer/SQL/Slice/SubqueryRemap.pm +++ b/lib/Data/Query/Renderer/SQL/Slice/SubqueryRemap.pm @@ -92,7 +92,9 @@ sub _subquery_remap { }; Order($mapped_by, $_->{reverse}); } else { - die "XXX not implemented yet"; + my $name = sprintf("ORDER__BY__%03i",++$order_gensym_count); + push @inside_select_list, Alias($name, $by); + Order(Identifier($name), $_->{reverse}); } } @inside_order;