hi all...
need help urgent....
i have 2 string stored in different field.
so i need to campare both string ..
let say $string1 = "ABCDABCD";
$string2 = "AAAAAAAA";
i use substr to compare it but it was very slow to compare about 15000 data..so could anyone suggest me other way..
below is my code.
for($i=0;$i<$total;$i++) {
$skema1=substr($skema,$i,1);
$obj_result1=substr($obj_result,$i,1);
if($skema1==$obj_result1){
$query1="update peperiksaan set obj_markah=obj_markah+1 where nokp='$nokp'";
$result1=pg_exec($link_id,$query1);
// echo "$obj_markah<br>";
}
}
}
$query1="update peperiksaan set marked='yes' where nokp='$nokp'";
$result1 = pg_exec($link_id,$query1);
}
need help urgent....
i have 2 string stored in different field.
so i need to campare both string ..
let say $string1 = "ABCDABCD";
$string2 = "AAAAAAAA";
i use substr to compare it but it was very slow to compare about 15000 data..so could anyone suggest me other way..
below is my code.
for($i=0;$i<$total;$i++) {
$skema1=substr($skema,$i,1);
$obj_result1=substr($obj_result,$i,1);
if($skema1==$obj_result1){
$query1="update peperiksaan set obj_markah=obj_markah+1 where nokp='$nokp'";
$result1=pg_exec($link_id,$query1);
// echo "$obj_markah<br>";
}
}
}
$query1="update peperiksaan set marked='yes' where nokp='$nokp'";
$result1 = pg_exec($link_id,$query1);
}