Hi guys,
please help me out. My problem is this: when I connect to MS Access through ADODB, I can retrieve text fields but not number or currency fields. Here is the code:
$SITE_Path = "C:\Apache\htdocs\";
$DB_Path = "DRIVER={Microsoft Access Driver (.mdb)}; DBQ=".$SITE_Path."db\";
$DB_Lemo = $DB_Path."test.mdb";
$conn = new COM("ADODB.Connection") or die("Cannot start ADO");
$conn->Open("$DB_Lemo");
$sql = "SELECT FROM destination";
$rs = $conn->Execute($sql);
while (!$rs->EOF) {
$db_rate = $rs->Fields("fromtodesc"); //text field, works fine
$rate = $db_rate->value;
$db_amt = $rs->Fields("basefee"); $amt = $db_amt->value; //currency field, crashes my php
echo $db_amt->value;
$rs->MoveNext();
$total++;
} / end while /
$rs->Close();
$conn->Close();
If anyone has encountered this or know why trying to get value of currency fields crashes php, PLEASE, let me know.
Thank you very much in advance.
Nazar