Index: trunk/extensions/SemanticMediaWiki/includes/storage/SMW_SQLStore2_Queries.php |
— | — | @@ -769,7 +769,7 @@ |
770 | 770 | $this->m_dbs->query("INSERT " . (($wgDBtype=='postgres')?"":"IGNORE") . " INTO $tmpnew (id) VALUES $values", 'SMW::executeHierarchyQuery'); |
771 | 771 | |
772 | 772 | for ($i=0; $i<$depth; $i++) { |
773 | | - $this->m_dbs->query("INSERT INTO $tmpres (id) SELECT s_id" . ($wgDBtype=='postgres'?'::integer':'') . " FROM $smw_subs2, $tmpnew WHERE o_id=id", |
| 773 | + $this->m_dbs->query("INSERT " . (($wgDBtype=='postgres')?'':'IGNORE ') . "INTO $tmpres (id) SELECT s_id" . ($wgDBtype=='postgres'?'::integer':'') . " FROM $smw_subs2, $tmpnew WHERE o_id=id", |
774 | 774 | 'SMW::executeHierarchyQuery'); |
775 | 775 | if ($this->m_dbs->affectedRows() == 0) { // no change, exit loop |
776 | 776 | break; |