Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

Is it possible to use MS Access 2010 as my Web Database instead of SQL

LuminariumLuminarium Posts: 8Member
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

Comments

  • miyliyevrmiyliyevr Posts: 1Member
    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>";
    }
    ?>
Sign In or Register to comment.