Re: COM

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Kiswa,

You are using mixing programming styles incorrectly.

"Kiswa" <Kiswa@telia.com> wrote in message
20030329091855.15126.qmail@pb1.pair.com">news:20030329091855.15126.qmail@pb1.pair.com...
> Server Win2000 +ISS5 +PHP
> Trying to get access to an access DB through COM but i wont work. there is
> no results generated.
> Can anyone help me
> Here is the code
>
> $rownum =0;
> $conn = &ADONewConnection('access');
> $conn->PConnect('webdb.mdb');
> $result = &$conn->Execute('SELECT Produkt, Artikelnr, Pris, Lagerstatus,
> Beskrivning, Kategori, Bild FROM Data');

Using ADOdb
>
>   while(odbc_fetch_row($result)){
>   $Produkt = odbc_result($result, Produkt);
>   $Artikelnr = odbc_result($result, Artikelnr);
>   $Pris = odbc_result($result, Pris);
>   $Lagerstatus = odbc_result($result, Lagerstatus);
>   $Beskrivning = odbc_result($result, Beskrivning);
>   $Kategori = odbc_result($result, Kategori);
>   $Bild = odbc_result($result, Bild);

Then using native odbc, which will not work because $result is an ADOdb
recordset,
and not odbc resultid.

Hope this helps. John

PS: ODBC does not use COM.



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux