4WebHelp
 FAQ  •  Search  •  User Groups  •  Forum Admins  •  Smilies List  •  Statistics  •  Rules   •  Login   •  Register
Toggle Navigation Menu

 Cannot connect PHP to MS Accesss Database
Post New TopicReply to Topic
View Previous Topic Print this topic View Next Topic
Author Message
scifo
Junior WebHelper
Junior WebHelper


Joined: 27 Jul 2003
Posts: 4

PostPosted: Sun Jul 27, 2003 12:36 am (14 years, 3 months ago) Reply with QuoteBack to Top

Hi,
Although I defined the System DSN I am having the error message below:
SQL error:[Microsoft][ODBC Microsoft Access Driver] Cannot modify the design of tabel 'testtable'. It is in a read-only database., SQL state 42000 in SQLExecDirect in c:inetpub\wwwroot\createtable.php on line 7
Code in createtable.php is as follows:

Code:
<?php
$connectionID = odbc_connect ("database.dsn","",""); //database.dsn is the name of system DSN
$statement = "CREATE TABLE testtable (name TEXT, telephone TEXT);";
odbc_do ($connectionID, $statement);
odbc_close = ($connectionID);
?>


As you can notice I am new in this subject and trying to use MS Access as th database of PHP pages by using windows XP IIS and the database in the same machine. The name of the database is "database" and saved in wwwroot directory.
Is there anyone who can help me????
Thanx in advance.
OfflineView User's ProfileFind all posts by scifoSend Personal Message
Darren
Team Member



Joined: 05 Feb 2002
Posts: 549
Location: London

PostPosted: Sun Jul 27, 2003 8:36 am (14 years, 3 months ago) Reply with QuoteBack to Top

As per the 'Forum Rules' the duplicate of this post has been removed from 'Server-Side Coding' - Please only post a question in one forum, thanks.
OfflineView User's ProfileFind all posts by DarrenSend Personal MessageVisit Poster's Website
Display posts from previous:      
Post New TopicReply to Topic
View Previous Topic Print this topic View Next Topic


 Jump to:   




You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot edit your posts in this forum.
You cannot delete your posts in this forum.
You cannot vote in polls in this forum.


Page generation time: 0.049645 seconds :: 17 queries executed :: All Times are GMT
Powered by phpBB 2.0 © 2001, 2002 phpBB Group :: Based on an FI Theme