Lines Matching refs:fields
572 function compare_stats( array $stat1, array $stat2, array $fields,
583 $fields = contains the key of the elements that needs to be compared.
593 function compare_stats($stat1, $stat2, $fields, $op = "==", $flag = false ) {
603 for($index = 0; $index < count($fields); $index++)
608 if ( $stat1[ $fields[$index] ] != $stat2[ $fields[$index] ] ) {
610 echo "Error: stat1 do not match with stat2 at key value: $fields[$index]\n";
615 if ( $stat1[ $fields[$index] ] != $stat2[ $fields[$index] ] ) {
619 echo "Error: stat1 equals stat2 at key value: $fields[$index]\n";
624 if ( $stat1[ $fields[$index] ] <= $stat2[ $fields[$index] ] ) {
626 echo "Error: stat1 is not greater than stat2 at key value: $fields[$index]\n";
631 if ( $stat1[ $fields[$index] ] >= $stat2[ $fields[$index] ] ) {
633 echo "Error: stat1 is not lesser than stat2 at key value: $fields[$index]\n";