Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeGetting StartedGetting StartedInstalling DNN ...Installing DNN ...Upgrade from 4.03.03 to 4.08.04 - SQLSchema ErrorUpgrade from 4.03.03 to 4.08.04 - SQLSchema Error
Previous
 
Next
New Post
7/2/2008 12:40 PM
 

I recently tried to upgrade to 4.8.4 using the upgrade package - modified all required files and ran the install script.  I received an SQLSchema error, and now I cannot get into the site.  Here is the ASP error page.

Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

Source Error:

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

Stack Trace:

[NullReferenceException: Object reference not set to an instance of an object.]
   DotNetNuke.Entities.Portals.PortalSettings.GetPortalSettings(Int32 TabId, PortalAliasInfo objPortalAliasInfo) +91
   DotNetNuke.Entities.Portals.PortalSettings..ctor(Int32 tabId, PortalAliasInfo objPortalAliasInfo) +83
   DotNetNuke.HttpModules.UrlRewriteModule.OnBeginRequest(Object s, EventArgs e) +3306
   System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +92
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +64

 

Here is the Schema log file

System.Data.SqlClient.SqlException: There is already an object named 'PK_EventLogMaster' in the database.
Could not create constraint. See previous errors.
   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
   at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
   at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
   at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
   at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async)
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
   at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
   at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)

ALTER TABLE dbo.[EventLog] ADD CONSTRAINT [PK_EventLogMaster] PRIMARY KEY CLUSTERED  ([LogGUID])


System.Data.SqlClient.SqlException: There is already an object named 'PK_EventLogTypes' in the database.
Could not create constraint. See previous errors.
   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
   at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
   at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
   at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
   at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async)
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
   at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
   at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)

ALTER TABLE dbo.[EventLogTypes] ADD CONSTRAINT [PK_EventLogTypes] PRIMARY KEY CLUSTERED  ([LogTypeKey])


System.Data.SqlClient.SqlException: There are no primary or candidate keys in the referenced table 'dbo.EventLogTypes' that match the referencing column list in the foreign key 'FK_EventLog_EventLogTypes'.
Could not create constraint. See previous errors.
   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
   at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
   at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
   at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
   at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async)
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
   at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
   at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)

ALTER TABLE dbo.[EventLog] ADD
CONSTRAINT [FK_EventLog_EventLogTypes] FOREIGN KEY ([LogTypeKey]) REFERENCES dbo.[EventLogTypes] ([LogTypeKey]),
CONSTRAINT [FK_EventLog_EventLogConfig] FOREIGN KEY ([LogConfigID]) REFERENCES dbo.[EventLogConfig] ([ID])


System.Data.SqlClient.SqlException: There are no primary or candidate keys in the referenced table 'dbo.EventLogTypes' that match the referencing column list in the foreign key 'FK_EventLogConfig_EventLogTypes'.
Could not create constraint. See previous errors.
   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
   at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
   at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
   at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
   at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async)
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
   at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
   at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)

ALTER TABLE dbo.[EventLogConfig] ADD
CONSTRAINT [FK_EventLogConfig_EventLogTypes] FOREIGN KEY ([LogTypeKey]) REFERENCES dbo.[EventLogTypes] ([LogTypeKey])

I downoaded the 4.8.4 install package and copied that over and modified the web.config file again, but it will not run the installer again.  Any ideas on how to fix this problem?  When I run the Install.aspx?mode=none, is says both the db and dnn are 4.8.4.

Hopefully this can be rectified without too much trouble.  Thanks, for the help.

 
New Post
7/3/2008 10:49 AM
 

Did some more checking in the database and my original configuration used the dnn_ prefix for all the tables.  After the upgrade it seems that it added all new tables without the prefix.  Is there a way to undo the upgrade and reinstall it making it see the dnn prefix on the tables?  I have access to the server and can manually delete the tables, but can you force the new install to use the existing table structure?

Please help, the site has been down for over a day now.

 
New Post
7/16/2008 11:29 AM
 

Found a partial solution, but new problems have come up.  I forgot to update the database qualifier to dnn for the tables in web.config.  After removing the added tables, modifying web.config with the table prefix and rerunning the installer, most everything successful except SQLprovider 04.04.00.log only stated "Error: HelpURL".  Everything else worked and the site is now accessible.  The only issue is the calendar modules and repository modules error stating a stored procedure is not available, yet both procedures are in the database.  Here is the error from one of the repository items.

Error: Downtown Board Documents is currently unavailable.
DotNetNuke.Services.Exceptions.ModuleLoadException: The stored procedure 'dbo.dnn_grmGetRepositoryCategories' doesn't exist. ---> System.InvalidOperationException: The stored procedure 'dbo.dnn_grmGetRepositoryCategories' doesn't exist. at System.Data.SqlClient.SqlCommand.DeriveParameters() at System.Data.SqlClient.SqlCommandBuilder.DeriveParameters(SqlCommand command) at Microsoft.ApplicationBlocks.Data.SqlHelperParameterCache.DiscoverSpParameterSet(SqlConnection connection, String spName, Boolean includeReturnValueParameter, Object[] parameterValues) at Microsoft.ApplicationBlocks.Data.SqlHelperParameterCache.GetSpParameterSetInternal(SqlConnection connection, String spName, Boolean includeReturnValueParameter) at Microsoft.ApplicationBlocks.Data.SqlHelperParameterCache.GetSpParameterSet(String connectionString, String spName, Boolean includeReturnValueParameter) at Microsoft.ApplicationBlocks.Data.SqlHelperParameterCache.GetSpParameterSet(String connectionString, String spName) at Microsoft.ApplicationBlocks.Data.SqlHelper.ExecuteReader(String connectionString, String spName, Object[] parameterValues) at DotNetNuke.Modules.Repository.SqlDataProvider.GetRepositoryCategories(Int32 ModuleID, Int32 RootID) at DotNetNuke.Modules.Repository.RepositoryCategoryController.GetRepositoryCategories(Int32 ModuleId, Int32 RootID) at DotNetNuke.Modules.Repository.Settings.BindCategoryList(Int32 root) at DotNetNuke.Modules.Repository.Settings.BindCategoryList() at DotNetNuke.Modules.Repository.Settings.Page_Load(Object sender, EventArgs e) --- End of inner exception stack trace ---

I am not sure what to do next.  If anyone has a solution to fix this error without having to start over, please let me know.

Thanks.

 
New Post
7/29/2008 3:46 PM
 

I have a very similar problem in my website. Also my users online module, my FAQ module and my media module are failing. The error message is related in all cases to unavailable stored procedures that already exist.

Error: Usuarios conectados no está disponible en este momento.
DotNetNuke.Services.Exceptions.ModuleLoadException: The stored procedure 'dbo.DNN_GetOnlineUserStatistics' doesn't exist. ---> System.InvalidOperationException: The stored procedure 'dbo.DNN_GetOnlineUserStatistics' doesn't exist. at System.Data.SqlClient.SqlCommand.DeriveParameters() at System.Data.SqlClient.SqlCommandBuilder.DeriveParameters(SqlCommand command) at Microsoft.ApplicationBlocks.Data.SqlHelperParameterCache.DiscoverSpParameterSet(SqlConnection connection, String spName, Boolean includeReturnValueParameter, Object[] parameterValues) at Microsoft.ApplicationBlocks.Data.SqlHelperParameterCache.GetSpParameterSetInternal(SqlConnection connection, String spName, Boolean includeReturnValueParameter) at Microsoft.ApplicationBlocks.Data.SqlHelperParameterCache.GetSpParameterSet(String connectionString, String spName, Boolean includeReturnValueParameter) at Microsoft.ApplicationBlocks.Data.SqlHelperParameterCache.GetSpParameterSet(String connectionString, String spName) at Microsoft.ApplicationBlocks.Data.SqlHelper.ExecuteReader(String connectionString, String spName, Object[] parameterValues) at DotNetNuke.Modules.UsersOnline.SqlDataProvider.GetStatistics(Int32 PortalId) at DotNetNuke.Modules.UsersOnline.UsersOnline.Page_Load(Object sender, EventArgs e) --- End of inner exception stack trace ---

 
Previous
 
Next
HomeHomeGetting StartedGetting StartedInstalling DNN ...Installing DNN ...Upgrade from 4.03.03 to 4.08.04 - SQLSchema ErrorUpgrade from 4.03.03 to 4.08.04 - SQLSchema Error


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out