[Bps-public-commit] r11367 - DBIx-SearchBuilder/trunk/SearchBuilder/Handle

ruz at bestpractical.com ruz at bestpractical.com
Tue Apr 1 22:49:40 EDT 2008


Author: ruz
Date: Tue Apr  1 22:49:40 2008
New Revision: 11367

Modified:
   DBIx-SearchBuilder/trunk/SearchBuilder/Handle/Oracle.pm

Log:
* move comment to the place where it must be

Modified: DBIx-SearchBuilder/trunk/SearchBuilder/Handle/Oracle.pm
==============================================================================
--- DBIx-SearchBuilder/trunk/SearchBuilder/Handle/Oracle.pm	(original)
+++ DBIx-SearchBuilder/trunk/SearchBuilder/Handle/Oracle.pm	Tue Apr  1 22:49:40 2008
@@ -258,8 +258,6 @@
 
     my $table = $sb->Table;
 
-    # Wrapp select query in a subselect as Oracle doesn't allow
-    # DISTINCT against CLOB/BLOB column types.
     if ($sb->_OrderClause =~ /(?<!main)\./) {
         # If we are ordering by something not in 'main', we need to GROUP
         # BY and adjust the ORDER_BY accordingly
@@ -269,6 +267,8 @@
         my $order = $sb->_OrderClause;
         $$statementref = "SELECT main.* FROM ( SELECT main.id FROM $$statementref $group $order ) distinctquery, $table main WHERE (main.id = distinctquery.id)";
     } else {
+        # Wrapp select query in a subselect as Oracle doesn't allow
+        # DISTINCT against CLOB/BLOB column types.
         $$statementref = "SELECT main.* FROM ( SELECT DISTINCT main.id FROM $$statementref ) distinctquery, $table main WHERE (main.id = distinctquery.id) ";
         $$statementref .= $sb->_GroupClause;
         $$statementref .= $sb->_OrderClause;



More information about the Bps-public-commit mailing list