[Linpha-cvs] SF.net SVN: linpha: [4868] trunk/linpha2/admin/maintenance_import.php
Status: Inactive
Brought to you by:
bzrudi
From: <bz...@us...> - 2008-02-12 13:36:00
|
Revision: 4868 http://linpha.svn.sourceforge.net/linpha/?rev=4868&view=rev Author: bzrudi Date: 2008-02-12 05:35:55 -0800 (Tue, 12 Feb 2008) Log Message: ----------- and again fixed missing FETCH_NUM statement (hopefully I got them all nailed now) Modified Paths: -------------- trunk/linpha2/admin/maintenance_import.php Modified: trunk/linpha2/admin/maintenance_import.php =================================================================== --- trunk/linpha2/admin/maintenance_import.php 2008-02-11 21:31:42 UTC (rev 4867) +++ trunk/linpha2/admin/maintenance_import.php 2008-02-12 13:35:55 UTC (rev 4868) @@ -407,14 +407,20 @@ * * nr images to index: (nr_total - nr_indexed) */ - $nr_total = $GLOBALS['linpha']->db->GetRow("SELECT sum(stats_numbers) FROM ".LIN_PREFIX."photos WHERE parent_id = '0' GROUP BY parent_id"); + $nr_total = $GLOBALS['linpha']->db->GetRow("SELECT sum(stats_numbers) AS s " . + "FROM ".LIN_PREFIX."photos " . + "WHERE parent_id = '0' " . + "GROUP BY parent_id"); + foreach($array_meta AS $value) { if($GLOBALS['linpha']->sql->config->value['sys_image_'.$value]) { - $nr_indexed = $GLOBALS['linpha']->db->GetRow("SELECT count(md5sum) FROM ".LIN_PREFIX."meta_".$value); + $nr_indexed = $GLOBALS['linpha']->db->GetRow("SELECT count(md5sum) " . + "AS number_idx " . + "FROM ".LIN_PREFIX."meta_".$value); - echo strtoupper($value).': '.i18n("Nr Images Needs Indexing:").' ' . ($nr_total[0] - $nr_indexed[0]) .' <br />'; + echo strtoupper($value).': '.i18n("Nr Images Needs Indexing:").' ' . ($nr_total['s'] - $nr_indexed['number_idx']) .' <br />'; } } ?> \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |