Script error upgrading site

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.

This thread is closed to new posts. You must sign in to post in the forums.
5/20/2013 6:06:21 AM
Gravatar
Total Posts 66

Script error upgrading site

I'm upgrading a site from 2.3.8.5 to the latest version from Codeplex (2.3.9.7 - for .Net4.) - mojoportal-2-3-9-7-mssql-net40-deploymentfiles

I have FTP'd the files from my local machine, amended web.config, and then logged onto the site to run the upgrade, but it is failing with the following error:

 

 mojoPortal Content Management System
Welcome to mojoPortal Setup
Probing system...
File system permissions ok.
MSSQL database connection ok.
database permissions are sufficient to alter schema.
database initial schema already exists.
database core schema needs upgrade.
1 site(s) found.
Running script mojoportal-core - 2.2.1.9 - 00:00:01.3884000
System.Data.SqlClient.SqlException (0x80131904):
Either the parameter @objname is ambiguous or the claimed @objtype (COLUMN) is wrong.
at System.Data.SqlClient.SqlConnection.OnError(SqlException exception,
Boolean breakConnection, Action`1 wrapCloseInAction) at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception,
Boolean breakConnection, Action`1 wrapCloseInAction) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj,
Boolean callerHasConnectionLock, Boolean asyncClose) at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream,
BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj,
Boolean& dataReady) at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async, Int32 timeout) at
System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource`1 completion, String methodName,
Boolean sendToPipe, Int32 timeout, Boolean asyncWrite) at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at mojoPortal.Data.SqlHelper.ExecuteNonQuery(SqlTransaction transaction, CommandType commandType, String commandText, Int32 commandTimeout, SqlParameter[] commandParameters)
at mojoPortal.Data.DBPortal.DatabaseHelperRunScript(String script, String overrideConnectionInfo) at mojoPortal.Data.DBPortal.DatabaseHelperRunScript(FileInfo scriptFile,
String overrideConnectionInfo) at mojoPortal.Business.DatabaseHelper.RunScript(Guid applicationId, FileInfo scriptFile, String overrideConnectionInfo)
ClientConnectionId:8a87eda0-8751-469c-b5ed-b3b709692e4c - 00:00:02.0124000

Could you suggest anything that may be wrong?

5/20/2013 7:35:02 AM
Gravatar
Total Posts 66

Re: Script error upgrading site

Further info - Hosted on Arvixe, using SQL2008R2

 

5/20/2013 7:53:51 AM
Gravatar
Total Posts 18439

Re: Script error upgrading site

Hi,

Something is wrong in your database, it should never try to run script version 2.2.1.9 since that is older than the version you started with. You need to update the row in the mp_SchemaVersion table that has mojoportal-core so it matches the version you started with ie 2.3.8.5 if you are sure that is your previous version. You could also look in the mp_SchemaScriptHistory to find the highest version script that was previously run for mojoportal-core then update mp_SchemaVersion with the correct previous version.

Once you correct the data in mp_SchemaVersion you should visit the setup page again and it should proceed starting at the next higher script ie 2.3.8.6

Hope that helps,

Joe

5/20/2013 8:32:22 AM
Gravatar
Total Posts 66

Re: Script error upgrading site

Very strange:

mp_schema_version is showing the following for mojoportal-core:

ApplicationName    Major    Minor    Build    Revision
mojoportal-core    2    2    1    8

The highest numbered script in mp_SchemaScriptHistory is 2.3.8.5, but the latest by ID is 2.2.1.8

I updated the version number to 2.3.8.5, then reran the setup, and things seem to have upgraded OK

Many thanks for the quick response
 

You must sign in to post in the forums. This thread is closed to new posts.