RE: [PHP] ODBC text file connection problem
| From: | Jay Blanchard | Date: | Tue, 10 Sep 2002 19:47:30 +0000 |
| Subject: | RE: [PHP] ODBC text file connection problem | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-115886@lists.php.net to get a copy of this message | ||
[snip]
$odbc = odbc_connect("cvalcoinput","","") OR die("There is an
error
connecting to the CSV file.");
$result = odbc_tables($odbc);
while(odbc_fetch_into($result, $fields)){
for ($i = 0; $i < sizeof($fields); $i++) {
echo $fields[$i] . "<br>";
}
}
Derives the following results:
D:\INETPUB\CVALCO\INCLUDE\INPUT
inputfile.txt
TABLE
[/snip]
I think that you need to have &$fields in your fetch_into statement.
Unfortunately I do not know of any good ODBC reference materials when it
comes to ODBC. I am sure that you Googled for it and had a look at the
manual, so I don't know where to point you now.
Jay
*****************************************************
* Texas PHP Developers Conf Spring 2003 *
* T Bar M Resort & Conference Center *
* New Braunfels, Texas *
* Contact jay.blanchard@niicommunications.com *
* *
* Want to present a paper or workshop? Contact now! *
*****************************************************