mojoPortal currently supports several database platforms including MS SQL, MySql, PostgreSQL, and SQLite.

Which database is used is determined by the reference from the Business logic layer, whichever data layer it references is used so you need to make sure it is referencing the one you want to use. I usually keep the reference set to PostgreSQL in the MonoDevelop solution and to MS SQL in the VS 2005 Solution when I commit to svn. To use a different db you need to set the reference.

Below is a screen shot of MonoDevelop showing the References beneath the Business project. In the screen shot it has a reference to the PostgreSQLData project.

To change the reference to MySQL, right click the PostgreSQLData reference and delete it. Then right click the References node and choose Edit References to open the Edit References Dialog.

Click on the Projects tab and scroll down to select MySQLData (not to be confused with MySql.Data). From the Project menu select Rebuild Solution. Edit the MySqlConnectionString in user.config and you are ready to use MySql.

Rate this Content 1 Votes