Microsoft Access
  Home arrow Microsoft Access arrow Page 3 - An Access Front-End to MySQL
ASP Free Forums 
.NET  
ASP  
ASP Code  
ASP.NET  
ASP.NET Code  
BrainDump  
C#  
Code Examples  
Database  
Database Code  
IIS  
Microsoft Access  
MS SQL Server  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
ASP Web Hosting  
ASP.NET Web Hosting 
Moblin 
JMSL Numerical Library 
Windows Web Hosting
 
IBM® developerWorks 
Sun Developer Network 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
MICROSOFT ACCESS

An Access Front-End to MySQL
By: Peter Lavin
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 4 stars4 stars4 stars4 stars4 stars / 22
    2004-07-28

    Table of Contents:
  • An Access Front-End to MySQL
  • Preliminary Steps
  • Limitations
  • State of the Union

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    An Access Front-End to MySQL - Limitations


    (Page 3 of 4 )

    First and foremost we know that data can be maintained using Access as a front-end. This is nothing to sniff at but what else can we do?

    Let’s try out some queries developed for use with a MySQL database.

    Look at the one below for example:

     SELECT DISTINCT tblusers.usercode as uc, monthbooked,
     daybooked, fldrate
     FROM tblrates, tblbookings, tblusers
     WHERE tblusers.usercode = tblbookings.usercode
     AND tblbookings.monthbooked = tblrates.fldmonth
     AND tblusers.billing = 1
     AND ISNULL(tblbookings.dateinvoiced)
     ORDER BY uc, monthbooked, daybooked

    This query executes within MySQL but when tried from Access, returns an error on the aliased field (“uc”) in the “ORDER BY” clause. This is remedied rather easily by replacing the aliased field with its actual name, “tblusers.usercode”. A promising start but the query:

     SELECT username FROM tblonline
     WHERE fldwhen > (SUBDATE(CURTIME(),
     INTERVAL '10' MINUTE))

    needs to be rewritten to use the Access-specific function “Datediff”. In fact no MySQL-specific functions may be used. Remember, you are dealing with linked tables from within Access, and this is going to limit the ability of the driver to support MySQL query syntax. It is for this reason that data definition queries on the linked tables, such as the one below, will not execute.

     ALTER TABLE tbllinks ADD COLUMN fldtype varchar(35)

    You can however create local tables from remote ones, and in some situations this can prove useful.

    Likewise none of the metadata methods of MySQL such as “SHOW” or “DESCRIBE” will work.

    It quickly becomes clear that linked tables are treated as though they were Access tables, so knowledge of Access SQL syntax is an absolute must if you wish to create queries.

    With large tables there may also be performance issues to consider when using Access as a front-end. Clicking on a linked table and bringing all the data across the network/internet will definitely slow performance.

    More Microsoft Access Articles
    More By Peter Lavin


       · One other thing worth mentioning is that if you use pass thru queries you can use...
       · Thanks for the article. I also found that an effective way to transfer a single...
       · 
       · 
       · Question?? I am trying to add records to a Mysql table using access. The primary...
       · RTFM ;-) *kidding*Have one more dummy column with TIMESTAMP as the data type,...
       · I have Access set up as a front end to a MySQL database. I have a form in Access...
       · I have Access set up as a front end to a MySQL database. I have a continuous...
       · The problem was fixed. When I created the column with TIMESTAMP as the data...
     

    MICROSOFT ACCESS ARTICLES

    - Linking SQL Express 2005 Tables to MS Access...
    - Working with Access Projects in Access 2007
    - Exploring Access 2007
    - Working with Stored Procedures in an MS Acce...
    - Creating and Using Action Queries
    - Creating Data Access Pages with Charts using...
    - Advanced Ideas using VBA
    - VBA Details
    - Updating Records in MS Access
    - Using ADO`s Record Object with URLs
    - Exporting XML from MS Access 2003
    - Importing XML into MS Access 2003
    - On Using Pass-through Queries in MS Access
    - Distributed Queries in MS Access
    - Configuring a Linked Microsoft Access Server...





    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway
    Stay green...Green IT