Explorar el Código

按照信心指数排序

visuddhinanda hace 5 años
padre
commit
fc96adfb56
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      app/dict/redis_sys_rgl_part.php

+ 1 - 1
app/dict/redis_sys_rgl_part.php

@@ -8,7 +8,7 @@ if (PHP_SAPI == "cli") {
 		$dbh = new PDO(_DICT_DB_REGULAR_, "", "", array(PDO::ATTR_PERSISTENT => true));
 		$dbh->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_WARNING);
 		
-		$query = "SELECT pali,parent,parts from "._TABLE_DICT_REGULAR_." where 1 group by pali";
+		$query = "select * from (SELECT pali,parts from "._TABLE_DICT_REGULAR_." where 1  order by confidence DESC ) where 1 group by pali";
 		$stmt = $dbh->query($query);
 		while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
 			# code...