Install Issue - Won't connect to SQL Server

Post here for help with installing or upgrading mojoPortal pre-compiled release packages. When posting in this forum, please provide all relevant details. You may also want to review the installation or upgrading documentation.

If you have questions about using the source code or working with mojoPortal in Visual Studio, please post in the Developer forum.

Post here for help with installation of mojoPortal pre-compiled release packages

When posting in this forum, please try to provide as many relevant details as possible. Particularly the following:

  • What operating system were you running when the bug appeared?
  • What database platform is your site using?
  • What version of mojoPortal are you running?
  • What version of .NET do you use?
  • What steps are necessary to reproduce the issue? Compare expected results vs actual results.

You may also want to review the installation or upgrading documentation.

If you have questions about using the source code or working with mojoPortal in Visual Studio, please post in the Developer forum.

5/2/2017 11:17:28 AM
Gravatar
Total Posts 1

Install Issue - Won't connect to SQL Server

I've only this entry in my user.config file:

  <add key="MSSQLConnectionString" value="server=localhost;UID=mojo;PWD=xxxx;database=Mojo" />
 

But I keep getting this error when trying to connect to the site:

 

An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.BadImageFormatException: An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)

Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[BadImageFormatException: An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)] Mono.Data.Sqlite.UnsafeNativeMethods.sqlite3_open(Byte[] utf8Filename, IntPtr& db) +0 Mono.Data.Sqlite.Sqlite3.Open(String strFilename) +54 Mono.Data.Sqlite.SqliteConnection.Open() +955 mojoPortal.Data.SqliteHelper.ExecuteNonQuery(String connectionString, String commandText, IDataParameter[] parameters) +128 mojoPortal.Data.DBTaskQueue.DeleteCompleted() +214 mojoPortal.Web.WebTaskManager.StartOrResumeTasks(Boolean appWasRestarted) +513 mojoPortal.Web.Global.StartOrResumeTasks() +362 mojoPortal.Web.Global.Application_Start(Object sender, EventArgs e) +323

 

Any thoughts? I did "touch" the Web.config file!

thank

JI

5/2/2017 11:49:34 AM
Gravatar
Total Posts 1991

Re: Install Issue - Won't connect to SQL Server

It looks like you are trying to use MSSQL with the SQLite version of mojoPortal. Download the MSSQL version of mojoPortal and you should be good to go.

Thanks,
Joe