-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I believe this change is also needed to the original patch submitted.
Minor change, but the original patch was allowing the following
statement, when it should have failed:
ij> select * from app.t intersect select * from app.t1 order by t.i;
I
- -----------
0 rows selected
Satheesh
[bandaram:satheesh] svn diff OrderByColumn.java
Index: OrderByColumn.java
===================================================================
- --- OrderByColumn.java (revision 111541)
+++ OrderByColumn.java (working copy)
@@ -172,7 +172,7 @@
ResultColumnList targetCols =
target.getResultColumns();
//bug 5716 - for db2 compatibility - no qualified names
allowed in order by clause when union/union all operator is used
- - if (target instanceof UnionNode && correlationName !=
null)
+ if (target instanceof SetOperatorNode && correlationName
!= null
)
{
String fullName = (schemaName != null) ?
(schemaName + "." + correlationName +
"." + columnName) :
[bandaram:satheesh]
Daniel John Debrunner wrote:
> For java source files that are completely new code (e.g.
> IntersectOrExceptNode.java) the copyright creation date should be 2004,
> not 1997.
>
> Can you explain why we need the classes ExceptNode.java and
> IntersectNode.java? They seem to provide little value and the code could
> be folded into the parent class easily. I'm always concerned about the
> footprint of Derby and each class file has overhead.
>
> Does the javadoc comment for SetOpProjectRestrictResultSet match what it
> is doing? Is a UNION ALL being used?
>
> +/**
> + * Takes the result set produced by an ordered UNION ALL of two tagged
> result sets and produces
> + * the INTERSECT or EXCEPT of the two input result sets. This also
> projects out the tag, the last column
> + * of the input rows.
> + */
>
> In SetOpProjectRestrictResultSet.compare() this code confused me for a
> while. It would be better written as a standard loop with the condition
> i < leftCols.length in the for operator, and then return 0 after the
> loop. Similar to how the next method isDuplicate() is coded.
>
> + for( int i = 0; ; i++)
> + {
> + if( i >= leftCols.length)
> + return 0;
>
>
>
>
> Dan.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (MingW32)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFBukILENVNIY6DZ7ERAmkOAJ4rEWnAYq/B1Top6pA33+2jxHn9SQCgjSnT
xXurNIAW5m7Z5pZTpCV41Zg=
=DhJj
-----END PGP SIGNATURE-----