Article ID: 920700 - Last Review: March 27, 2007 - Revision: 8.4 An introduction to SQL Server 2005 Compact EditionNote SQL Server 2005 Compact Edition was named SQL Server 2005 Everywhere Edition during the product development phase. Through the pre-release Community Technology Preview (CTP) program and through other channels, customers have communicated to Microsoft that this product name may cause confusion with other database product names in the industry. Microsoft has taken this feedback seriously and has accordingly changed the official product name. On This PageINTRODUCTIONMicrosoft SQL Server 2005 Compact Edition (SQL Server Compact Edition) is the rebranding of Microsoft SQL Server 2005 Mobile Edition (SQL Server Mobile 3.0) without the desktop restriction. SQL Server Mobile 3.0 was released in 2005 with Microsoft Visual Studio 2005 and with SQL Server 2005. SQL Server Mobile 3.0 is supported on devices and on Tablet PCs. SQL Server Mobile 3.0 is also partially supported on desktop computers. To use SQL Server Mobile 3.0 on desktop computers, either Visual Studio 2005 or SQL Server 2005 must be installed. However, with SQL Server Compact Edition, this restriction has been removed. With SQL Server Compact Edition, you can develop and deploy applications independent of SQL Server 2005 and of Visual Studio 2005. The SQL Server Compact Edition Community Technology Preview (CTP) was released on June 12, 2006. SQL Server Compact Edition Release Candidate 1 (RC1) was released on November 7, 2006. Both the CTP version and the RC1 version of SQL Server Compact Edition were only for runtime binaries. The Release to Web (RTW) version of SQL Server Compact Edition for all packages was released on January 15, 2007. The version of SQL Server Compact Edition RTW is 3.1. The following packages were released together with the RTW version of SQL Server Compact Edition:
MORE INFORMATIONSQL Server Compact Edition Runtime (SQLServerCE31-EN.msi)SQL Server Compact Edition contains the runtime bits that can be used to develop applications and to deploy applications on desktop computers and on Tablet PCs. SQL Server Compact Edition is a powerful yet lightweight relational database engine. SQL Server Compact Edition supports familiar SQL syntax. Additionally, SQL Server Compact Edition provides a development model and an API that are consistent with SQL Server. Therefore, you can more easily develop desktop applications by using the RTW version of SQL Server Compact Edition than by using SQL Server Mobile. SQL Server Compact Edition includes new features such as |DataDirectory| substitution string support and ClickOnce support so that deployment is easy.To download the SQL Server Compact Edition Runtime, visit the following Microsoft Web site: http://www.microsoft.com/downloads/details.aspx?familyid=85e0c3ce-3fa1-453a-8ce9-af6ca20946c3
(http://www.microsoft.com/downloads/details.aspx?familyid=85e0c3ce-3fa1-453a-8ce9-af6ca20946c3)
The SQL Server Compact Edition Runtime binary includes the following DLLs:
To register the OLE DB provider, you must have Administrator permissions. Therefore, you cannot install SQL Server Compact Edition unless you have Administrator permissions. The Windows Installer package installs these binaries in the "%ProgramFiles%\Microsoft SQL Server Compact Edition\v3.1" folder. After you install SQL Server Compact Edition, a Microsoft SQL Server 2005 Compact Edition entry is added in Add or Remove Programs. To install the localized version (SQLServerCE31-[LN].msi), you must install the English version (SQLServerCE31-EN.msi) first, and then install the localized version. Note [LN] represents the localized language. SQL Server Compact Edition Tools for Visual Studio 2005 SP1 (SSCE31VSTools-ENU.exe)SQL Server Compact Edition Tools for Visual Studio 2005 SP1 updates the Microsoft Visual Studio 2005 SP1 smart device development components by using the design time environment for SQL Server Compact Edition.To download SQL Server Compact Edition Tools for Visual Studio 2005 SP1, visit the following Microsoft Web site: http://www.microsoft.com/downloads/details.aspx?FamilyId=877C0ADC-0347-4A47-B842-58FB71D159AC&displaylang=en
(http://www.microsoft.com/downloads/details.aspx?FamilyId=877C0ADC-0347-4A47-B842-58FB71D159AC&displaylang=en)
To install the localized version (SSCE31VSTools-[LN].exe), you must install the English version (SSCE31VSTools-ENU.exe) first, and then install the localized version.SQL Server Compact Edition Developer SDK (SSCE31SDK-ENU.msi)SQL Server Compact Edition Developer SDK contains the following files for developing applications by using SQL Server Compact Edition as a database store for the applications:
http://www.microsoft.com/downloads/details.aspx?FamilyId=E9AA3F8D-363D-49F3-AE89-64E1D149E09B&displaylang=en
(http://www.microsoft.com/downloads/details.aspx?FamilyId=E9AA3F8D-363D-49F3-AE89-64E1D149E09B&displaylang=en)
The English version of SQL Server Compact Edition Developer SDK contains only the English version of SQL Server Compact Edition Runtime. The localized version of SQL Server Compact Edition Developer SDK contains the English version of SQL Server Compact Edition Runtime and the localized version SQL Server Compact Edition Runtime. After you install SQL Server Compact Edition Developer SDK, the installer package for SQL Server Compact Edition Runtime is located in the following folder:%programfiles%\Microsoft SQL Server Compact Edition\v3.1\SDK\bin\Desktop To install the localized version of SQL Server Compact Edition Runtime from the localized version of SQL Server 2005 Compact Edition Developer SDK, follow these steps:
SQL Server Compact Edition Server Tools (Sqlce30setupen.msi)To download SQL Server Compact Edition Server Tools, visit the following Microsoft Web site:http://www.microsoft.com/downloads/details.aspx?FamilyId=4E45F676-E69A-4F7F-A016-C1585ACF4310&displaylang=en
(http://www.microsoft.com/downloads/details.aspx?FamilyId=4E45F676-E69A-4F7F-A016-C1585ACF4310&displaylang=en)
Note To install the localized version (Sqlce30setup[LN].msi), you do not have to install the English version (Sqlce30setupen.msi) first.SQL Server Compact Edition Books Online (SSCE31BOL-EN.msi)SQL Server Compact Edition Books Online installs the documentation for SQL Server Compact Edition.To download SQL Server Compact Edition Books Online, visit the following Microsoft Web site: http://www.microsoft.com/downloads/details.aspx?FamilyId=E6BC81E8-175B-46EA-86A0-C9DACAA84C85&displaylang=en
(http://www.microsoft.com/downloads/details.aspx?FamilyId=E6BC81E8-175B-46EA-86A0-C9DACAA84C85&displaylang=en)
Note To install the localized version (SSCE31BOL-[LN].msi), you do not have to install the English version (SSCE31BOL-EN.msi) first. Side-by-side installation together with Visual Studio 2005 or SQL Server 2005SQL Server Mobile 3.0 requires Visual Studio 2005 or SQL Server 2005 to be installed on the computer. However, SQL Server Compact Edition does not have this requirement. Therefore, users can develop and deploy SQL Server Compact Edition applications without having SQL Server 2005 or Visual Studio 2005 installed. However, this change may cause some behavior changes on a computer that has SQL Server Compact Edition installed together with Visual Studio 2005 or with SQL Server 2005. Users experience the following behavior in a side-by-side installation together with Visual Studio 2005 or with SQL Server 2005.Visual Studio 2005 behaviorVisual Studio 2005 together with SQL Server Compact Edition
Visual Studio 2005 SP1 together with SQL Server Compact Edition
SQL Server 2005 behaviorSQL Server 2005 or SQL Server 2005 SP1 together with SQL Server Compact Edition
SQL Server 2005 SP2 together with SQL Server Compact Edition
New featuresSQL Server Compact Edition includes some features that are not included in SQL Server Mobile 3.0. These features include the following:
|DataDirectory| substitution string support|DataDirectory| (enclosed in pipe symbols) is a substitution string that indicates the database path. Therefore, you do not have to include the full path in the code. When you include the full path in the code, you may experience problems because the full database path can be serialized in different locations. The |DataDirectory| substitution string also makes it easy to share a project and to deploy an application.For example, if you include the full path in the code, the application can have the following connection string.
ClickOnce supportClickOnce is a new software installation technology that SQL Server Compact Edition supports. ClickOnce simplifies the deployment of a Windows-based application to a Web server or to a network file share. Administrators can deploy or update an application by updating the files on a server. Administrators do not have to individually update every client.Visual Studio provides full support for publishing and updating applications that are deployed by using ClickOnce. ClickOnce support is available for projects that are created by using Microsoft Visual Basic, Microsoft Visual C#, and Microsoft Visual J#. However, ClickOnce support is not available for projects that are created by using Microsoft Visual C++. You can download SQL Server Compact Edition Tools for Visual Studio 2005 SP1 and install it on Visual Studio 2005 SP1. This installs the integrated support for ClickOnce and installs the required ClickOnce files in the correct directory. How to integrate ClickOnce with SQL Server Compact EditionNote The descriptions of the files and the folders in this section use the English version of SQL Server Compact Edition. If you install another language version of SQL Server Compact Edition, the locale name in the file names and in the folder names may differ. For example, the locale name may be "Zh" instead of "EN."To integrate ClickOnce with SQL Server Compact Edition, download SQL Server Compact Edition Tools for Visual Studio 2005 SP1 and install it on Visual Studio 2005 SP1. This installs the integrated support for ClickOnce. The required ClickOnce files are also installed in the appropriate directory. The following table describes the ClickOnce files. Collapse this table
Collapse this table
Performance improvementsIn SQL Server Compact Edition 3.1, some default values for input parameters are changed for desktop computers to improve the performance. However, these default values remain unchanged for mobile devices for performance reasons. The following table shows the old default values and the new default values for both mobile devices and desktop computers.Collapse this table
Note If you receive error messages that are related to these input parameters in SQL Server Compact Edition 3.1, the error messages still display the old values for these input parameters. This problem occurs because the error messages are not updated to reflect the new values in SQL Server Compact Edition 3.1. This problem will be fixed in the next release of SQL Server Compact Edition. Known issues for SQL Server Compact Edition 3.1 on Windows VistaThe SQL Server Compact Edition Runtime is supported on Windows Vista. The database functionality is thoroughly tested on Windows Vista. However, there are some known functional issues in SQL Server Compact Edition 3.1 on Windows Vista. The following sections describe the functional issues and the suggested workarounds.To maintain backward compatibility, the database encryption feature of SQL Server 2005 Compact Edition uses the same encryption algorithms as SQL Server 2005 Mobile Edition. Those algorithms are now somewhat outdated and do not provide a level of security that satisfies the standard Microsoft product policies. We recommend that you use another way to help secure the data where you can, for example, Encrypting File System. Issue 1When you use the Configure Web Synchronization Wizard to configure Microsoft Internet Information Services (IIS) 7.0 on Windows Vista, you receive the following error message:IIS not installed Note The Configure Web Synchronization Wizard sets various parameters in IIS to enable the synchronization between SQL Server Compact Edition and SQL Server. Workaround for issue 1To work around this issue, follow these steps:
Issue 2When you run SQL Server Compact Edition Server Tools (Sqlce30setupen.msi) Setup under Least Privilege to User Accounts (LUA) mode on Windows Vista, you receive the following error message:SQL Server Replication Components not found Workaround for issue 2Open a Command Prompt window that has elevated privileges, and then run the Sqlce30setupen.msi file.Issue 3When you run SQL Server Compact Edition Server Tools (Sqlce30setupen.msi) Setup under silent mode on Windows Vista, the installation fails.This issue occurs when you specify the default user setting not to use elevated privileges. This issue occurs because the Setup program does not prompt you to use elevated privileges. Instead, the Setup program uses the default user setting for elevated privileges. Workaround for issue 3Specify the default user setting to use elevated privileges before you run SQL Server Compact Edition Server Tools.Issue 4Consider the following scenario. You have a computer that is running Visual Studio 2005. You upgrade the operating system on this computer to Windows Vista. In this scenario, the SQL Server Compact Edition 3.1 integration with Visual Studio 2005 is broken.SQL Server Compact Edition 3.1 contains the SQL Server Compact Edition Tools for Visual Studio 2005 SP1 package. This package installs the components to integrate SQL Server Compact Edition 3.1 with Visual Studio 2005. This package also adds some registry entries that Visual Studio 2005 uses. After you upgrade the operating system to Windows Vista, the integration is broken. Workaround for issue 4To work around this issue, follow these steps:
Issue 5Consider the following scenario. You have a computer that is running Windows Server 2008. You install SQL Server 2005 Service Pack 2 on this computer. In the Connect Database dialog box in SQL Server Management Studio, you create a new SQL Server Compact Edition database. In this scenario, you notice that the database is created in the %WINDIR%\SYSTEM32 folder.Workaround for issue 5Specify a path together with the file name when you create a new SQL Server Compact Edition database in SQL Server Management Studio.Other known issues for SQL Server Compact Edition 3.1Issue 1Consider the following scenario. You publish a localized SQL Server Compact Edition 3.1 application by using ClickOnce. Then, you deploy this application to another computer. In this scenario, the localized version of the SQL Server Compact Edition Runtime is not installed.Workaround for issue 1To work around this issue, create your own package .xml file for ClickOnce. Do this to make sure that the localized version of the SQL Server Compact Edition Runtime is installed when you deploy the application.For more information about how to add prerequisites to an application, visit the following Microsoft Developer Network Web site (MSDN): http://msdn2.microsoft.com/en-us/library/ms165429(VS.80).aspx
(http://msdn2.microsoft.com/en-us/library/ms165429(VS.80).aspx)
Issue 2Consider the following scenario. You install the English version of the SQL Server Compact Edition Runtime. Then, you install a localized version of the SQL Server Compact Edition Runtime on the same computer. In this scenario, you notice that the following entry is deleted from the Machine.config file when you uninstall the SQL Server Compact Edition Runtime:SQL Server Compact Edition Data Provider Note The Machine.config file is in the following folder: Microsoft.NET\Framework\v2.0.50727\CONFIG%WinDir This issue may cause problems in provider-agnostic applications.Workaround for issue 2To work around this issue, use one of the following methods:
Issue 3You cannot install the SQL Server Compact Edition Tools for Visual Studio 2005 SP1 side by side for different language versions on the same computer.Note You can install Visual Studio 2005 SP1 side by side for different language versions on the same computer. Issue 4In SQL Server Compact Edition 3.1, you cannot use the sp_repladdcolumn stored procedure to perform the following operations in one SQL statement:
Workaround for issue 4Create two SQL statements to perform the operations separately.For example, create the following SQL statements to perform the operations that you want. Software updatesSQL Server Compact Edition 3.1 resolves many bugs that occur in earlier versions of SQL Server Compact Edition. The following list describes some of the bugs that SQL Server Compact Edition 3.1 resolves:
| Article Translations
|
Back to the top
