Microsoft Office Online
Sign in to My Office Online (What's this?) | Sign in

 
 
Microsoft Office Access
Search
Search
 
Icon: Flag: (c) Microsoft
Get up to speed
 
 
 
Warning: You are viewing this page with an unsupported Web browser. This Web site works best with Microsoft Internet Explorer 6.0 or later, Firefox 1.5, or Netscape Navigator 8.0 or later. Learn more about supported browsers.

Which file format should I use in Access?
 
Applies to
Microsoft Access 2002

Unlike in previous versions of Access, users who upgrade to Access 2002 don't need to convert files created with Access 2000 to a new format in order to continue using them. Files in Access 2000 file format, both Access databases (.mdb) and Access projects (.adp), can now be used directly in an Access 2002 application by using the default Access 2000 file format. Conversely, files developed with Access 2002 using the default Access 2000 file format can be used in Access 2000 without conversion. This makes it simple and straightforward to share files in a mixed Access 2000 and Access 2002 application environment.

However, when you want to use Access 2002-specific features and ensure that only Access 2002 users can open your files, you should use the Access 2002 file format.

Why the new choice?

Access 2002 uses Access 2000 as the default file format so that Access 2000 users can upgrade while continuing to use their existing databases and Access projects without interruptions or conversions. In an environment with mixed Access 2000 and Access 2002 installations, the default Access 2000 file format ensures that all users will be able to share files. The following table shows the compatibility between file formats from a particular version of Access and other versions of Access. "Yes" means that the file can be used in the application without conversion.

File Format Compatible with Access 97? Compatible with Access 2000? Compatible with Access 2002?
Access 97 format (created with Access 97) Yes No No
Access 2000 format (created with Access 2000) No Yes Yes
Access 2000 format (created with Access 2002) No Yes (Access 2000 features only) Yes
Access 2002 format (created with Access 2002) No No Yes

Figure 1. Table of File Format Compatibilities between Different Versions of Access

Note   In an Access 2002 application, the features available to files in Access 2000 file format are exactly the same as those available to Access 2002 files. However, the Access 2002-specific features are unavailable when any file in Access 2002 file format is opened in Access 2000.

Sharing files between Access 2000 and Access 2002

Users who move their files from an Access 2000 application to an Access 2002 application will enjoy all of the new features and added functionality. Things will work as they always have before conversion — only better. Additionally, Access 2002 users can share their files with Access 2000 users without having to worry that users opening the files in Access 2000 will lose any of the Access 2002-specific features. Access 2000 users will be able to open and use the files, but with some reduced functionality. For example, in an Access 2002 application, a user can include a PivotTable® view in a form or report to assist in analyzing data. When that same file is opened in an Access 2000 application, the data will be displayed as a datasheet, which allows the user to continue working with the data. When the file is then reopened in an Access 2002 application, it will appear again as a PivotTable view, along with any data that was added by the Access 2000 user.

Access 2000 users who modify macros or other objects will see some changes when using files created with Access 2002. For example, macros that contain Access 2002-specific actions will appear "commented out" when used in an Access 2000 application.

Additionally, in Access 2002, the capacity of the Recordsource property was increased to handle Structured Query Language (SQL) statements up to 32,000 characters in length. Access 2000 files that were created in Access 2002 and then used in an Access 2000 application can execute those long statements but can't save them. If a user modifies the long Recordsource property of an Access 2000 file while the file is in Access 2000, and then attempts to save the object, he will see a message that says the Recordsource property is too long. He will then need to modify the Recordsource string to fit the old size of 2,000 characters, or use the file only with Access 2002.

Changes for Access 2000 developers

Visual Basic for Applications (VBA) code in files that were created with Access 2002 by using the default Access 2000 file format will run more slowly in Access 2000 than VBA code in Access 2000-created files. If you compile VBA code in an Access 2000 file while in Access 2002 and then open that file in Access 2000, the code will become decompiled. This means that Access 2000 will need to recompile those portions of the file before running them. This recompilation will make the Access 2000 VBA code run more slowly than if the same file were created and used in Access 2002. It is therefore recommended that developers compile and compact files in Access 2000 before deploying them to a mixed environment.

.mde and .ade files must be created with Access 2002

Converting an Access database (.mdb) or Access project (.adp) to an .mde or .ade file, respectively, helps protect the intellectual property of developers by removing the source code from VBA functions and subroutines. This leaves only the compiled code, which cannot be viewed in a usable format; this security feature helps protect the code from someone wanting to copy, thus, the code is safe from someone wanting to copy it. However, the compiled code remaining in the .mdb or .adp file must still make calls to specific Access properties and methods. Because new properties and methods have been added to Access 2002, any calls to these properties or methods from a file being used in Access 2000 would cause errors. To prevent this from happening, Access 2002 can only create .mde or .ade files from Access 2002 files.

Here is a summary of .mde and .ade file compatibility:

  • .mde and .ade files created in Access 2000 can be opened in Access 2002 without any problems.
  • .mde and .ade files created with Access 2002 cannot be opened in Access 2000.
  • .mde and .ade files can be created only in Access 2002 when using the Access 2002 file format, not the default Access 2000 file format. This helps protect both developers and end users from inadvertently opening a potentially incompatible file in Access 2000 and ensures that all features will work as expected.

Programmability differences in Access 2002

There are several new features and options in Access 2002, all of which are accessible by files in Access 2000 file format when they are used in Access 2002. To ensure that files created with Access 2002 in Access 2000 file format continue to be compatible when used in Access 2000, references to the default data access object model, in this case ActiveX Data Objects (ADO) 2.1, and the SQL syntax (ANSI SQL 89) for the Microsoft Jet database engine (.mdb) files, were retained.

To implement the new features and technologies available in Access 2002, the base compatibility level of Access 2002 files was changed to a new default data access model (ADO 2.5) and a new SQL syntax (ANSI SQL 92), and included references to the Microsoft Office Web Components. For more information about the new programmability features added in Access 2002, see the Visual Basic Editor Help topic "What's New for Microsoft Access 2002 Developers."

In addition, when new PivotTable views and PivotChart® views are created in Access 2002, references to the Office Web Components are automatically created so that developers can use the methods and properties associated with the Web Component object models. These references are created only in Access 2002 files, not Access 2000 files.

About Access 97 databases

Unlike files in Access 2000 file format, Access 97 files must be converted to Access 2000 or Access 2002 file format in order to be used in Access 2002. The Convert To Access 97 File Format option is included in Access 2002 so that users can convert their Access 2002 and Access 2000 files back to Access 97, but with reduced functionality. (To do this, open the Tools menu, click Database Utilities, and then click Convert Database.)

For more information about converting or enabling Access 97 files, see Access 2002 Help.

advertisement