SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    midnight coder
    Join Date
    Dec 2000
    Location
    The flat edge of the world
    Posts
    838
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    My friend wants to get a MS Access database online, and it's kinda in a hurry.

    I haven't learnt ASP yet, the only web language I know is PHP. If I can't convince him to convert the database to MySQL, I'll probably have to make MS Access a DSN for ODBC and use PHP to communicate with it.

    I tried out some stuff at home, and is having some trouble already. I always use mysql_fetch_array in my scripts, but there doesn't appear to be any odbc_fetch_arrary, only odbc_fetch_row. So how would I display a certain column?

    The script kinda goes like:

    PHP Code:
    <?

    $dbcnx 
    odbc_connect ($dbname,'',$pass) or die(odbc_error());

    $sql odbc_exec ($dbcnx'SELECT FirstName, LastName FROM "Mail List"');

    while (
    odbc_fetch_row($sql));
    {
        
    $first odbc_result($sql,1);
        
    $last odbc_result($sql,2);

        echo 
    "$first$last<br />";
    }

    ?>
    Of course, it only gives one result, since it's odbc_fetch_row, what is the equivilant to mysql_fetch_array?

    And is there any sources on the web that's on the subject of PHP and ODBC? Every little bit helps...

  2. #2
    Dumb PHP codin' cat
    Join Date
    Aug 2000
    Location
    San Diego, CA
    Posts
    5,460
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Please don't PM me with questions.
    Use the forums, that is what they are here for.

  3. #3
    Serial Publisher silver trophy aspen's Avatar
    Join Date
    Aug 1999
    Location
    East Lansing, MI USA
    Posts
    12,937
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Access is seriously not a good DB - and while it'll be fine for some smaller sites that don't get traffic or that dont execute queries on every page it won't do good for bigger sites.

    But just to throw out another option you can learn a little coldfusion (which is about the easiest thing in the world to learn) and do it like that.
    Chris Beasley - I publish content and ecommerce sites.
    Featured Article: Free Comprehensive SEO Guide
    My Guide to Building a Successful Website
    My Blog|My Webmaster Forums

  4. #4
    SitePoint Wizard westmich's Avatar
    Join Date
    Mar 2000
    Location
    Muskegon, MI
    Posts
    2,328
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Not to pick a fight or side-track this discussion, but what do you mean by Access not being a good database?

    I've "heard" folks talk on message boards, but have seen little in the way of facts.
    • Access will store up to 10,000 records, which is more then most Web sites would ever need.
    • Access 2000 will support 150 concurrent users. The record for SitePointForums is 157 and they have users in the millions per month.
    • Has many of the features of a true RDBMS, more then MySQL.
    • Access works well as a desktop solution and integrates well within a Microsoft/Office environment.
    • Many PC users already have it and develop solutions on their desktop and easily migrate to a server.

    Granted it doesn't compare to Oracle, SQL Server, or PostgreSQL, but to say it is bad is a bit much.
    Last edited by westmich; Apr 27, 2001 at 14:24.
    Westmich
    Smart Web Solutions for Smart Clients
    http://www.mindscapecreative.com

  5. #5
    Serial Publisher silver trophy aspen's Avatar
    Join Date
    Aug 1999
    Location
    East Lansing, MI USA
    Posts
    12,937
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I don't know about that 150 user thing.

    We had a client that had an employees only section of their website. The password system was ASP with a Access backend and they were always running into problems so we had to switch them up to SQL Server.

    They don't have a whole lot of employees - much much less than 100.

    Access is a desktop database - don't expect to run a popular or query heavy site off of it.
    Chris Beasley - I publish content and ecommerce sites.
    Featured Article: Free Comprehensive SEO Guide
    My Guide to Building a Successful Website
    My Blog|My Webmaster Forums


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •