Hello, all!
I am connecting to another machine that's running SQL Server 7. For auth reasons, I cannot use mssql syntax in coding pages, but rather have to use ODBC functions.
My problem comes in trying to assign php-usable var names to data retrieved from my query. The page doesn't bomb, but i don't get my expected results, and I have checked the DB to make sure the data is actually in there, and that my query string will access it.
When I try to echo one of the variables I've supposedly assigned, I get an "Undefined Variable" warning in the browser.
My variable assignments look like this:
$result=odbc_exec($conn, $query);
while(odbc_fetch_row($result)) {
$ProjectStatus=odbc_result($result, 1);
$StatusDate=odbc_result($result, 2);
$Phase=odbc_result($result, 3);
$PhaseStatus=odbc_result($result, 4);
$ActualsToDate=odbc_result($result, 5);
$EstimateToComplete=odbc_result($result, 6);
$EstimateAtCompletion=odbc_result($result, 7);
$CostVariance=odbc_result($result, 8);
$Notes=odbc_result($result, 9);
echo("<tr><td>$ProjectStatus</td>"/n);
echo("<td>$StatusDate</td>"/n);
echo("<td>$Phase</td>"/n);
echo("<td>$PhaseStatus</td>"/n);
echo("<td>$ActualsToDate</td>"/n);
echo("<td>$EstimateToComplete</td>"/n);
echo("<td>$EstimateAtComplete</td>"/n);
echo("<td>$CostVariance</td>"/n);
echo("<td>$Notes</td></tr>"/n);
}
Anyone got any hints on this for me....? Thanks!