RE: [PHP-DB] How to access a MS Access DB
| From: | Jonathan Villa | Date: | Fri, 14 Feb 2003 16:12:11 +0000 |
| Subject: | RE: [PHP-DB] How to access a MS Access DB | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-25636@lists.php.net to get a copy of this message | ||
Ok, this is what I did...
Keep in mind I have Xp so I don't know how this all pans out.
1. I opened the ODBC Data Source Administrator
2. My default view was User DSN
3. I clicked on System DSN
4. Clicked on Add
5. Choose Microsoft Access Driver (*.mdb)
6. Gave it a name of Killerspin_com2
7. Clicked on Create
8. Saved it the directory which my source code will reside in.
9. Set up username/password
10. created test_connect.php page.
11. Inserted the following code:
if (odbc_connect("killerspin_com","username","password") == 0)
die("failed");
else
die("success");
12. Received this error.
Warning: SQL error: [Microsoft][ODBC Driver Manager] Data source name
not found and no default driver specified, SQL state IM002 in SQLConnect
in D:\is\clients\eki\killer_spin\new_web\test_connect.php on line 3
Failed.
I'm not to sure how to set this up to work with PHP
---> Jonathan
-----Original Message-----
From: Griffiths, Daniel [mailto:DANIEL.GRIFFITHS@conconf.org]
Sent: Friday, February 14, 2003 3:38 AM
To: jvilla@isdesigndev.com; php-db@lists.php.net
Subject: RE: [PHP-DB] How to access a MS Access DB
to set up a DSN go to control panel and then Administrative Tools then
into Data Sources and then add a new system DSN.
you can probably work the rest out as its fairly straight forward.
-----Original Message-----
From: Jonathan Villa [mailto:jvilla@isdesigndev.com]
Sent: 13 February 2003 22:48
To: php-db@lists.php.net
Subject: [PHP-DB] How to access a MS Access DB
I need to know exactly how to hook up to an Access database under Office
Xp. I normally use MySQL, but the current site sits on Windows servers.
I am using php 4.3.0
Office Xp Pro w/ Access
I'm running Apache 2.0.43
I need to know how to check if ODBC is set up on my machine (I hear that
by default it is) and what's this about a driver?
All I know at this point is
odbc_connect("XXX","username","password");
Where XX is the DSN name I will be using, (how do this, i.e. set up a
DSN name)
Thanks much and in advance.
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php