RE: How to access a MS Access DB

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

 



I believe I posted that thread.


Try odbc_exec instead of odbc_prepare

Let me know if have more problems
 
---> Jonathan
 
 
 

-----Original Message-----
From: Beverly Steiner [mailto:steiner277@charter.net] 
Sent: Monday, March 03, 2003 3:11 PM
To: php-db@lists.php.net
Cc: Beverly Steiner
Subject: RE:  How to access a MS Access DB

Hello,

I'm new to this list and saw a past discussion in mid-Feb. about how to
access an MS Access DB.  I have Apache and PHP installed on my PC
running XP
Professional.

I created a system DSN and got past the odbc_connect but it died in the
odbc_prepare statement.  Error message: Warning: odbc_prepare():
supplied
argument is not a valid ODBC-Link resource in c:\perl\htdocs\test2.php
on
line 20
cannot prepare result

Here's my code (w/username and password changed):

$connection = odbc_connect("mctadb", "username", "password") ||
die("cannot
open database");

$sql = "SELECT MeeetingTitle, MeetingDate FROM meeting;";

$sql_result = odbc_prepare($connection, $sql) || die("cannot prepare
result");

Any help would be greatly appreciated,

Beverly Steiner
steiner277@charter.net



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



-- 
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