[Fusionforge-commits] r7653 - trunk/gforge/common/tracker

Alain Peyrat aljeux at libremir.placard.fr.eu.org
Thu May 14 21:59:51 CEST 2009


Author: aljeux
Date: 2009-05-14 21:59:50 +0200 (Thu, 14 May 2009)
New Revision: 7653

Modified:
   trunk/gforge/common/tracker/ArtifactFactory.class.php
Log:
Fix broken sql query in getArtifacts()

Modified: trunk/gforge/common/tracker/ArtifactFactory.class.php
===================================================================
--- trunk/gforge/common/tracker/ArtifactFactory.class.php	2009-05-14 19:08:18 UTC (rev 7652)
+++ trunk/gforge/common/tracker/ArtifactFactory.class.php	2009-05-14 19:59:50 UTC (rev 7653)
@@ -265,7 +265,7 @@
 		
 		$selectsql = 'SELECT DISTINCT ON (group_artifact_id, artifact_id) artifact_vw.* FROM artifact_vw';
 
-		$wheresql = 'WHERE group_artifact_id=$'.$paramcount++ ;
+		$wheresql = ' WHERE group_artifact_id=$'.$paramcount++ ;
 		$params[] = $this->ArtifactType->getID() ;
 
 		if (is_array($this->extra_fields) && !empty($this->extra_fields)) {
@@ -353,7 +353,7 @@
 							    'assigned_to',
 							    'submitted_by',
 							    'priority'));
-		$ordersql = " ORDER BY Artifacts.group_artifact_id.$sortorder, Artifacts.$sortcol $sortorder" ;
+		$ordersql = " ORDER BY Artifacts.group_artifact_id $sortorder, Artifacts.$sortcol $sortorder" ;
 
 		$result = db_query_params ('SELECT * FROM (' . $selectsql . $wheresql . ') AS Artifacts' . $ordersql,
 					   $params) ;




More information about the Fusionforge-commits mailing list