We have an old database we are trying to upgrade from R12- I get this error after the upgrade ran when I try to access the site. We ran into similar errors once when we tried to move the database.
Any help would be appreciated. There were numerous other errors during the upgrade and I had to remove some DTA indexes that had been added.
Incorrect syntax near '@errorNumber'.
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.Data.SqlClient.SqlException: Incorrect syntax near '@errorNumber'.
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:
[SqlException (0x80131904): Incorrect syntax near '@errorNumber'.]
System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) +265
System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) +714
System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) +4496
System.Data.SqlClient.SqlDataReader.TryConsumeMetaData() +108
System.Data.SqlClient.SqlDataReader.get_MetaData() +93
System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted) +551
System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest) +3307
System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry) +650
System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) +117
System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) +368
NHibernate.AdoNet.AbstractBatcher.ExecuteReader(DbCommand cmd) +473
NHibernate.Id.InsertSelectDelegate.ExecuteAndExtract(DbCommand insert, ISessionImplementor session) +78
NHibernate.Id.Insert.AbstractReturningDelegate.PerformInsert(SqlCommandInfo insertSQL, ISessionImplementor session, IBinder binder) +119
[GenericADOException: could not insert: [CommerceBuilder.Users.User][SQL: INSERT INTO ac_Users (StoreId, UserName, LoweredUserName, Email, LoweredEmail, AffiliateId, AffiliateReferralDate, PrimaryWishlistId, PayPalId, PasswordQuestion, PasswordAnswer, IsApproved, IsAnonymous, IsLockedOut, CreateDate, LastActivityDate, LastLoginDate, LastPasswordChangedDate, LastLockoutDate, FailedPasswordAttemptCount, FailedPasswordAttemptWindowStart, FailedPasswordAnswerAttemptCount, FailedPasswordAnswerAttemptWindowStart, TaxExemptionType, TaxExemptionReference, Comment) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?); select SCOPE_IDENTITY()]]
NHibernate.Id.Insert.AbstractReturningDelegate.PerformInsert(SqlCommandInfo insertSQL, ISessionImplementor session, IBinder binder) +371
NHibernate.Persister.Entity.AbstractEntityPersister.Insert(Object[] fields, Object obj, ISessionImplementor session) +276
NHibernate.Action.EntityIdentityInsertAction.Execute() +194
NHibernate.Engine.ActionQueue.Execute(IExecutable executable) +44
NHibernate.Event.Default.AbstractSaveEventListener.PerformSaveOrReplicate(Object entity, EntityKey key, IEntityPersister persister, Boolean useIdentityColumn, Object anything, IEventSource source, Boolean requiresImmediateIdAccess) +846
NHibernate.Event.Default.AbstractSaveEventListener.SaveWithGeneratedId(Object entity, String entityName, Object anything, IEventSource source, Boolean requiresImmediateIdAccess) +253
NHibernate.Event.Default.DefaultSaveOrUpdateEventListener.SaveWithGeneratedOrRequestedId(SaveOrUpdateEvent event) +96
NHibernate.Event.Default.DefaultSaveOrUpdateEventListener.EntityIsTransient(SaveOrUpdateEvent event) +139
CommerceBuilder.DomainModel.SaveOrUpdateEventListener.PerformSaveOrUpdate(SaveOrUpdateEvent event) +216
NHibernate.Event.Default.DefaultSaveOrUpdateEventListener.OnSaveOrUpdate(SaveOrUpdateEvent event) +343
NHibernate.Impl.SessionImpl.FireSaveOrUpdate(SaveOrUpdateEvent event) +91
NHibernate.Impl.SessionImpl.SaveOrUpdate(Object obj) +80
CommerceBuilder.DomainModel.RepositoryWithTypedId`2.Save(TEntity item) +141
CommerceBuilder.DomainModel.Repository`1.Save(TEntity item) +56
CommerceBuilder.Users.UserRepository.Save(User item) +114
Edited by user Wednesday, April 6, 2022 11:19:34 AM(UTC)
| Reason: Not specified