Converting recordset into array
Posted: Wed Apr 04, 2012 10:03 am
I have a custom function to calculate the median of an array. I need help to convert all of a certain field in a found set to an array as used in the following code snippet.
It would be best to somehow use an if statement to convert to an array as in the case of:
to use in place here:
Thanks for all of your help!
It would be best to somehow use an if statement to convert to an array as in the case of:
- Code: Select all
if ($record->val('FieldB') == "string"){
Add $record->val('FieldB') to array
to use in place here:
- Code: Select all
include ("ajstatistics.php");
$a = array(0, 1, 2, 3, 4, 5);
$the_median = median($a);
Thanks for all of your help!