db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From b..@apache.org
Subject cvs commit: jakarta-ojb/src/java/org/apache/ojb/broker/accesslayer/sql SqlQueryStatement.java
Date Mon, 16 Dec 2002 18:23:19 GMT
brj         2002/12/16 10:23:19

  Modified:    src/java/org/apache/ojb/broker/accesslayer/sql
                        SqlQueryStatement.java
  Log:
  multiple orderby for CollectionDescriptor
  
  Revision  Changes    Path
  1.14      +8 -7      jakarta-ojb/src/java/org/apache/ojb/broker/accesslayer/sql/SqlQueryStatement.java
  
  Index: SqlQueryStatement.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ojb/src/java/org/apache/ojb/broker/accesslayer/sql/SqlQueryStatement.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- SqlQueryStatement.java	16 Nov 2002 18:06:30 -0000	1.13
  +++ SqlQueryStatement.java	16 Dec 2002 18:23:19 -0000	1.14
  @@ -66,6 +66,7 @@
   import org.apache.ojb.broker.metadata.ClassDescriptor;
   import org.apache.ojb.broker.metadata.CollectionDescriptor;
   import org.apache.ojb.broker.metadata.FieldDescriptor;
  +import org.apache.ojb.broker.metadata.FieldHelper;
   import org.apache.ojb.broker.metadata.ObjectReferenceDescriptor;
   import org.apache.ojb.broker.platforms.Platform;
   import org.apache.ojb.broker.platforms.PlatformFactory;
  @@ -685,7 +686,7 @@
   	 */
   	protected void appendOrderByClause(List orderByFields, int[] orderByColumnNumbers, StringBuffer
buf)
   	{
  -		Criteria.Field cf;
  +		FieldHelper cf;
   
   		if (orderByColumnNumbers == null)
   		{
  @@ -695,7 +696,7 @@
   		buf.append(" ORDER BY ");
   		for (int i = 0; i < orderByColumnNumbers.length; i++)
   		{
  -			cf = (Criteria.Field) orderByFields.get(i);
  +			cf = (FieldHelper) orderByFields.get(i);
   			if (i > 0)
   			{
   				buf.append(",");
  @@ -713,7 +714,7 @@
   	 */
   	protected void appendGroupByClause(List groupByFields, StringBuffer buf)
   	{
  -		Criteria.Field cf;
  +		FieldHelper cf;
   
   		if (groupByFields == null || groupByFields.size() == 0)
   		{
  @@ -723,7 +724,7 @@
   		buf.append(" GROUP BY ");
   		for (int i = 0; i < groupByFields.size(); i++)
   		{
  -			cf = (Criteria.Field) groupByFields.get(i);
  +			cf = (FieldHelper) groupByFields.get(i);
   			if (i > 0)
   			{
   				buf.append(",");
  @@ -860,12 +861,12 @@
   	 */
   	protected int[] ensureColumns(List columns, List existingColumns, StringBuffer buf)
   	{
  -		Criteria.Field cf;
  +        FieldHelper cf;
   		int[] columnNumbers = new int[columns.size()];
   
   		for (int i = 0; i < columnNumbers.length; i++)
   		{
  -			cf = (Criteria.Field) columns.get(i);
  +			cf = (FieldHelper) columns.get(i);
   			columnNumbers[i] = existingColumns.indexOf(cf.name);
   			if (columnNumbers[i] == -1)
   			{
  
  
  

Mime
View raw message