PageRenderTime 20ms CodeModel.GetById 13ms RepoModel.GetById 0ms app.codeStats 0ms


Plain Text | 94 lines | 71 code | 23 blank | 0 comment | 0 complexity | a375d4d7dcf5fa0668e6c8aa7b027f58 MD5 | raw file
Possible License(s): LGPL-2.1, Apache-2.0, BSD-3-Clause
  1. Running BlogEngine.NET using SQL CE 4.0
  2. If you wish to use SQL CE to store all your blog data, this folder has all the information you'll
  3. likely need. The BlogEngine.sdf is already setup with the DB tables and initial data needed
  4. to get started with BlogEngine.NET. Although not needed, SQL_CE_Setup_2.9.sql is provided
  5. for reference. This was the setup script used to create the BlogEngine.sdf file.
  6. Instructions for New Setup
  7. -----------------------------------------------------------
  8. 1. When running BlogEngine.NET under SQL CE 4.0, you will either need SQL CE 4.0 installed on
  9. your computer, or if deploying to a webhost, you can simply copy the SQL CE 4.0 binary (DLL)
  10. files to your /BIN directory. The DLL files will be located in the installation folder for SQL
  11. CE 4.0. The installation folder is located at:
  12. %ProgramFiles(x86)%\Microsoft SQL Server Compact Edition\v4.0\Private
  13. If you do not have SQL CE 4.0 installed on your computer, or you need the DLL files, the latest
  14. CTP version of SQL CE 4.0 can be downloaded at:
  16. However, please check for the latest version of SQL CE 4.0 before downloading the one at the
  17. above link.
  18. 2. Copy the following files/folders to your /BIN directory. The files are located in the SQL CE
  19. 4.0 installation folder:
  20. %ProgramFiles(x86)%\Microsoft SQL Server Compact Edition\v4.0\Private
  21. (a) Copy the file "System.Data.SqlServerCe.dll" into your /BIN directory.
  22. (b) There are two sub-folders: AMD64 and X86. Copy both folders to your /BIN directory.
  23. After copying these files and folders, your /BIN directory will look like this:
  24. /bin
  25. System.Data.SqlServerCe.dll
  26. /bin/x86
  27. sqlceca40.dll
  28. sqlcecompact40.dll
  29. sqlceer40EN.dll
  30. sqlceme40.dll
  31. sqlceqp40.dll
  32. sqlcese40.dll
  33. /bin/amd64
  34. sqlceca40.dll
  35. sqlcecompact40.dll
  36. sqlceer40EN.dll
  37. sqlceme40.dll
  38. sqlceqp40.dll
  39. sqlcese40.dll
  40. 3. Rename the SQL_CE_Web.Config file to web.config and copy it to your blog's root
  41. folder. (This will overwrite your existing web.config file. If this is not a new installation,
  42. make sure you have a backup.)
  43. 4. Copy the BlogEngine.sdf file into the App_Data folder.
  44. 5. Surf out to your Blog and see the welcome post.
  45. 6. Login with the username admin and password admin. Change the password.
  46. Upgrading from 2.6
  47. -----------------------------------------------------------
  48. - Run SQL_CE_UpgradeFrom2.6to3.0.sql against your existing CE database. It will add new table and index.
  49. If you get an error with "GO" keyword not supported, run statements one by one excluding "; GO".
  50. Upgrading from 2.5
  51. -----------------------------------------------------------
  52. There is an upgrade script to update your SDF file so it is compliant with BlogEngine.NET 2.7.
  53. The upgrade script name is SQL_CE_UpgradeFrom2.5to2.6.sql. This script will need to be
  54. run against your BlogEngine.NET 2.5 SDF file. A recommended tool is to use the
  55. SQL Server Compact Toolbox utility found at:
  57. An add-in for Visual Studio 2010/2012 can be downloaded, or a standalone version of the toolbox
  58. can be downloaded. This utility will allow you to run a SQL CE script against a SDF
  59. file. You would want to run the script contained in SQL_CE_UpgradeFrom2.5to2.6.sql
  60. against your BlogEngine.NET 2.5 SDF file. Once the script has been run, your BlogEngine.SDF
  61. file will be ready to use in a BlogEngine.NET 2.5 website.
  62. Additionally, the web.config file has changed from 2.5 to 2.7. It will likely be easiest to start
  63. with the sample web.config file as described above, but if you have other changes in it,
  64. you'll need to merge them. Don't forget to move your connectionString over.
  65. Troubleshooting
  66. -----------------------------------------------------------
  67. If you use one of the sample web.config files, are running your site on your own machine or a
  68. server that SQL CE 4.0 is already installed on, and you receive the following error message
  69. when starting the site:
  70. "Failed to find or load the registered .Net Framework Data Provider."
  71. In this scenario, you may need to remove the <> section out of the web.config file.