0
I’m half a day trying to do this.
I have this loop
if(@mysqli_num_rows($sql_es_1_aux) == 1){
echo "";
}else{
$sql_es_1 = mysqli_query($config, "SELECT peso FROM tb_sub_agrupamento
WHERE id_ctr IN ($id_ctr_ok) AND
peso <> ''") or die(mysqli_error($config));
if(@mysqli_num_rows($sql_es_1) <= '0'){
echo "";
}else{
while($r_sql_es_1 = mysqli_fetch_array($sql_es_1)){
$peso_sel_es1 = $r_sql_es_1[0];
}
}
}
$peso_sel_es1 may be repeated.
Is there any way to check if it is repeated outside the while?
If I turn it into array (putting []) help?
I need to determine that if it’s repeated, don’t show the weight.
You want to display the repeated value only once right?
– Thiagosilr
Not exactly. I need to check only if it exists or not repeated. After checking, it will be a simple if. If it has repeated it does not show the block.
– Rogério Pancini