|
|
@ -318,16 +318,44 @@ elseif ($action=='update_checkmd5') |
|
|
|
|
|
|
|
echo "<br><br><b>update checkmd5 done !</b>" ; |
|
|
|
|
|
|
|
$query="select count(checkmd5) as smd5 from importation_data_aidimpact group by checkmd5 having smd5>1"; |
|
|
|
$query="select checkmd5,count(checkmd5) as smd5 from importation_data_aidimpact group by checkmd5 having smd5>1"; |
|
|
|
|
|
|
|
$res=mysqli_query($conn, $query); |
|
|
|
$num=mysqli_num_rows($res); |
|
|
|
echo '<br>'.$num; |
|
|
|
|
|
|
|
if ($num > 0) { |
|
|
|
echo "<table border='1' style='border-collapse: collapse;'>"; |
|
|
|
echo "<tr><td>Date import</td><td>Nom fichier</td><td>idt</td><td>no_compte</td><td>code_JNL</td><td>No_piece</td><td>date_piece</td><td>lib_mouvement</td><td>debit</td><td>credit</td><td>code_activite</td></tr>"; |
|
|
|
while ($row = mysqli_fetch_assoc($res)) { |
|
|
|
$query2="SELECT date_import,filename,d.idt,no_compte,code_JNL,No_piece,
|
|
|
|
DATE_FORMAT(date_piece,'%d/%m/%Y')as date_piece, |
|
|
|
lib_mouvement,IFNULL(debit,'') as debit,IFNULL(credit,'') as credit, |
|
|
|
code_activite from importation_data_aidimpact d |
|
|
|
inner join importation i on i.id=d.id |
|
|
|
WHERE checkmd5='".$row['checkmd5']."';";
|
|
|
|
|
|
|
|
$result2=mysqli_query($conn, $query2); |
|
|
|
while ($row = mysqli_fetch_assoc($result2)) { |
|
|
|
|
|
|
|
echo "<tr><td>".$row['date_import']."</td><td>".$row['filename']."</td><td>".$row['idt']."</td><td>".$row['no_compte']."</td><td>".$row['code_JNL']."</td><td>".$row['No_piece']."</td><td>".$row['date_piece']."</td><td>".$row['lib_mouvement']."</td><td>".$row['debit']."</td><td>".$row['credit']."</td><td>".$row['code_activite']."</td></tr>"; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
echo "</table>"; |
|
|
|
|
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
echo (mysqli_num_rows($result)); |
|
|
|
} |
|
|
|
// Close opened CSV file
|
|
|
|
fclose($myfile); |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
else |
|
|
|
{ |
|
|
|
echo "action error"; |
|
|
|