".htmlentities($msg["nettoyage_rdfstore_reindexation"], ENT_QUOTES, $charset)."

"; $q_sel = " select t.t as num_triple, s.val as subject_uri, p.val as predicat_uri, o.id as num_object, o.val as object_val, l.val as object_lang from rdfstore_triple t, rdfstore_s2val s, rdfstore_id2val p, rdfstore_o2val o, rdfstore_id2val l where t.o_type=2 and t.o_lang_dt=l.id and length(l.val)<3 and t.s=s.id and t.p=p.id and t.o=o.id order by t.t LIMIT $start, $lot"; $r_sel = mysql_query($q_sel,$dbh); if(mysql_num_rows($r_sel)) { // définition de l'état de la jauge $state = floor($start / ($count / $jauge_size)); $state .= "px"; // mise à jour de l'affichage de la jauge print "
"; print "
"; // calcul pourcentage avancement $percent = floor(($start/$count)*100); // affichage du % d'avancement et de l'état print "
$percent%
"; require_once("$class_path/rdf/ontology.class.php"); $op = new ontology_parser("$class_path/rdf/skos_pmb.rdf"); $sh = new skos_handler($op); while(($triple = mysql_fetch_object($r_sel))){ $type=$sh->op->from_ns($sh->get_object_type($triple->subject_uri)); $q_ins = "insert ignore into rdfstore_index "; $q_ins.= "set num_triple='".$triple->num_triple."', "; $q_ins.= "subject_uri='".addslashes($triple->subject_uri)."', "; $q_ins.= "subject_type='".addslashes($type)."', "; $q_ins.= "predicat_uri='".addslashes($triple->predicat_uri)."', "; $q_ins.= "num_object='".$triple->num_object."', "; $q_ins.= "object_val ='".addslashes($triple->object_val)."', "; $q_ins.= "object_index=' ".strip_empty_chars($triple->object_val)." ', "; $q_ins.= "object_lang ='".addslashes($triple->object_lang)."' "; $r_ins = mysql_query($q_ins,$dbh); } $next = $start + $lot; print "
"; } else { $spec = $spec - INDEX_RDFSTORE; $not = mysql_query("select count(1) from rdfstore_triple where o_type=2", $dbh); $compte = mysql_result($not, 0, 0); $v_state .= "
".htmlentities($msg['nettoyage_rdfstore_reindexation'], ENT_QUOTES, $charset)." : "; $v_state .= $compte." ".htmlentities($msg['nettoyage_rdfstore_reindex_elt'], ENT_QUOTES, $charset); print "
"; } ?>