Access

Moderators: None (Apply to moderate this forum)
Number of threads: 1075
Number of posts: 2224

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
Is it possible to use MS Access 2010 as my Web Database instead of SQL Posted by Luminarium on 2 Dec 2010 at 7:05 AM
well ask the title says, i want to make a Web Database and flexibly connect it on my web pages (similar to MySQL).

Hope anyone here who could help me, thanks guys
Report
Re: Is it possible to use MS Access 2010 as my Web Database Posted by miyliyevr on 5 Sept 2011 at 1:06 PM
I think you are using PHP. I used access 2007 file as database. I'm working on Windows XP with XAMPP's apache server. Create your database file and try this :
1. First enter to --> Control Panel > Administartive Tools > Data Sources(ODBC) > System DSN > Add.. > Microsoft Access Driver(*.mdb,*.accdb) and show your access file. Give name to the connection.
2. Then write in your .php file this code:
<?php
$host= "Name_You_gave_to_connection";
$user= "";
$pass= "";
$db=odbc_connect($host,$user,$pass); //connect to access file as database

if (!$db) //In case if you didn't connect , you'll get an error message
{
echo "Can't connect";
exit;
}

$query = "SELECT * FROM table_name";
$row = odbc_exec($db, $query);
while(odbc_fetch_row($row)
{
$row1 = odbc_result($row,1);
$row2 = odbc_result($row,2);
$row3 = odbc_result($row,3);
echo $row1." ".$row2." ".$row3."<br>";
}
?>



 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.