This probem has been driving me bonkers for days.....
Rather that use ODBC_RESULT_ALL I wanted to be able to do something with my retrieved records so I wrote a bit of code to print each record field by field, then line by line.
The problem is I can't see a way to refer to each variable ($col2 in this case) uniquely when they are passed as variables to a php program - is anything like this possble?
I just can't think of any way to do this.
while (odbc_fetch_row($result))
{
// Get first column
$col1 = odbc_result($result,1);
// Print contents of first field
echo ("$col1 \n");
// Get second column
$col2 = odbc_result($result,2);
// Print contents of second field as a link
echo "<a href=\"call a php program with variables\"> $col2 </a> <BR>";
}
Thanks
Chris