YAFLogo

rainbow77
  • rainbow77
  • 65.8% (Friendly)
  • YAF Forumling Topic Starter YAF Version: 1.9.301
3 months ago
if I try again:

Quote:

FILE:
install/mssql/upgrade/identity/upgrade.sql

ERROR:
There is already an object named 'yaf_AspNetUsers' in the database.

STATEMENT:
CREATE TABLE [dbo].[yaf_AspNetUsers](
   [Id]            NVARCHAR (128) NOT NULL,
   [UserName]      NVARCHAR (MAX) NULL,
   [PasswordHash]  NVARCHAR (MAX) NULL,
   [SecurityStamp] NVARCHAR (MAX) NULL,
   [EmailConfirmed]       BIT            NOT NULL,
   [PhoneNumber]          NVARCHAR (MAX) NULL,
   [PhoneNumberConfirmed] BIT            NOT NULL,
   [TwoFactorEnabled]     BIT            NOT NULL,
   [LockoutEndDateUtc]    DATETIME       NULL,
   [LockoutEnabled]       BIT            NOT NULL,
   [AccessFailedCount]    INT            NOT NULL,
   [ApplicationId]                          UNIQUEIDENTIFIER NOT NULL,
   [LegacyPasswordHash]  NVARCHAR (MAX) NULL,
   [LoweredUserName]  NVARCHAR (256)   NOT NULL,
   [MobileAlias]      NVARCHAR (16)    DEFAULT (NULL) NULL,
   [IsAnonymous]      BIT              DEFAULT ((0)) NOT NULL,
   [LastActivityDate] DATETIME2         NOT NULL,
   [MobilePIN]                              NVARCHAR (16)    NULL,
   [Email]                                  NVARCHAR (256)   NULL,
   [LoweredEmail]                           NVARCHAR (256)   NULL,
   [PasswordQuestion]                       NVARCHAR (256)   NULL,
   [PasswordAnswer]                         NVARCHAR (128)   NULL,
   [IsApproved]                             BIT              NOT NULL,
   [IsLockedOut]                            BIT              NOT NULL,
   [CreateDate]                             DATETIME2               NOT NULL,
   [LastLoginDate]                          DATETIME2         NOT NULL,
   [LastPasswordChangedDate]                DATETIME2         NOT NULL,
   [LastLockoutDate]                        DATETIME2         NOT NULL,
   [FailedPasswordAttemptCount]             INT              NOT NULL,
   [FailedPasswordAttemptWindowStart]       DATETIME2         NOT NULL,
   [FailedPasswordAnswerAttemptCount]       INT              NOT NULL,
   [FailedPasswordAnswerAttemptWindowStart] DATETIME2         NOT NULL,
   [Comment]                                NTEXT            NULL,
   [Profile_Birthday] DateTime NULL,
   [Profile_Blog] NVARCHAR (255) NULL,
   [Profile_Gender] INT NULL,
   [Profile_GoogleId] NVARCHAR (255) NULL,
   [Profile_Homepage] NVARCHAR (255) NULL,
   [Profile_Facebook] NVARCHAR (400) NULL,
   [Profile_FacebookId] NVARCHAR (400) NULL,
   [Profile_Twitter] NVARCHAR (400) NULL,
   [Profile_TwitterId] NVARCHAR (400) NULL,
   [Profile_Interests] NVARCHAR (400) NULL,
   [Profile_Location] NVARCHAR (255) NULL,
   [Profile_Country] NVARCHAR (2) NULL,
   [Profile_Region] NVARCHAR (255) NULL,
   [Profile_City] NVARCHAR (255) NULL,
   [Profile_Occupation] NVARCHAR (400) NULL,
   [Profile_RealName] NVARCHAR (255) NULL,
   [Profile_Skype] NVARCHAR (255) NULL,
   [Profile_XMPP] NVARCHAR (255) NULL
   CONSTRAINT [PK_dbo.AspNetUsers] PRIMARY KEY CLUSTERED ([Id] ASC)
   /*FOREIGN KEY ([ApplicationId]) REFERENCES [dbo].[aspnet_Applications] ([ApplicationId]),*/
);
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.Exception: FILE:
install/mssql/upgrade/identity/upgrade.sql

ERROR:
There is already an object named 'yaf_AspNetUsers' in the database.

STATEMENT:
CREATE TABLE [dbo].[yaf_AspNetUsers](
   [Id]            NVARCHAR (128) NOT NULL,
   [UserName]      NVARCHAR (MAX) NULL,
   [PasswordHash]  NVARCHAR (MAX) NULL,
   [SecurityStamp] NVARCHAR (MAX) NULL,
   [EmailConfirmed]       BIT            NOT NULL,
   [PhoneNumber]          NVARCHAR (MAX) NULL,
   [PhoneNumberConfirmed] BIT            NOT NULL,
   [TwoFactorEnabled]     BIT            NOT NULL,
   [LockoutEndDateUtc]    DATETIME       NULL,
   [LockoutEnabled]       BIT            NOT NULL,
   [AccessFailedCount]    INT            NOT NULL,
   [ApplicationId]                          UNIQUEIDENTIFIER NOT NULL,
   [LegacyPasswordHash]  NVARCHAR (MAX) NULL,
   [LoweredUserName]  NVARCHAR (256)   NOT NULL,
   [MobileAlias]      NVARCHAR (16)    DEFAULT (NULL) NULL,
   [IsAnonymous]      BIT              DEFAULT ((0)) NOT NULL,
   [LastActivityDate] DATETIME2         NOT NULL,
   [MobilePIN]                              NVARCHAR (16)    NULL,
   [Email]                                  NVARCHAR (256)   NULL,
   [LoweredEmail]                           NVARCHAR (256)   NULL,
   [PasswordQuestion]                       NVARCHAR (256)   NULL,
   [PasswordAnswer]                         NVARCHAR (128)   NULL,
   [IsApproved]                             BIT              NOT NULL,
   [IsLockedOut]                            BIT              NOT NULL,
   [CreateDate]                             DATETIME2               NOT NULL,
   [LastLoginDate]                          DATETIME2         NOT NULL,
   [LastPasswordChangedDate]                DATETIME2         NOT NULL,
   [LastLockoutDate]                        DATETIME2         NOT NULL,
   [FailedPasswordAttemptCount]             INT              NOT NULL,
   [FailedPasswordAttemptWindowStart]       DATETIME2         NOT NULL,
   [FailedPasswordAnswerAttemptCount]       INT              NOT NULL,
   [FailedPasswordAnswerAttemptWindowStart] DATETIME2         NOT NULL,
   [Comment]                                NTEXT            NULL,
   [Profile_Birthday] DateTime NULL,
   [Profile_Blog] NVARCHAR (255) NULL,
   [Profile_Gender] INT NULL,
   [Profile_GoogleId] NVARCHAR (255) NULL,
   [Profile_Homepage] NVARCHAR (255) NULL,
   [Profile_Facebook] NVARCHAR (400) NULL,
   [Profile_FacebookId] NVARCHAR (400) NULL,
   [Profile_Twitter] NVARCHAR (400) NULL,
   [Profile_TwitterId] NVARCHAR (400) NULL,
   [Profile_Interests] NVARCHAR (400) NULL,
   [Profile_Location] NVARCHAR (255) NULL,
   [Profile_Country] NVARCHAR (2) NULL,
   [Profile_Region] NVARCHAR (255) NULL,
   [Profile_City] NVARCHAR (255) NULL,
   [Profile_Occupation] NVARCHAR (400) NULL,
   [Profile_RealName] NVARCHAR (255) NULL,
   [Profile_Skype] NVARCHAR (255) NULL,
   [Profile_XMPP] NVARCHAR (255) NULL
   CONSTRAINT [PK_dbo.AspNetUsers] PRIMARY KEY CLUSTERED ([Id] ASC)
   /*FOREIGN KEY ([ApplicationId]) REFERENCES [dbo].[aspnet_Applications] ([ApplicationId]),*/
);

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:

[Exception: FILE: install/mssql/upgrade/identity/upgrade.sql ERROR: There is already an object named 'yaf_AspNetUsers' in the database. STATEMENT: CREATE TABLE [dbo].[yaf_AspNetUsers]( [Id] NVARCHAR (128) NOT NULL, [UserName] NVARCHAR (MAX) NULL, [PasswordHash] NVARCHAR (MAX) NULL, [SecurityStamp] NVARCHAR (MAX) NULL, [EmailConfirmed] BIT NOT NULL, [PhoneNumber] NVARCHAR (MAX) NULL, [PhoneNumberConfirmed] BIT NOT NULL, [TwoFactorEnabled] BIT NOT NULL, [LockoutEndDateUtc] DATETIME NULL, [LockoutEnabled] BIT NOT NULL, [AccessFailedCount] INT NOT NULL, [ApplicationId] UNIQUEIDENTIFIER NOT NULL, [LegacyPasswordHash] NVARCHAR (MAX) NULL, [LoweredUserName] NVARCHAR (256) NOT NULL, [MobileAlias] NVARCHAR (16) DEFAULT (NULL) NULL, [IsAnonymous] BIT DEFAULT ((0)) NOT NULL, [LastActivityDate] DATETIME2 NOT NULL, [MobilePIN] NVARCHAR (16) NULL, [Email] NVARCHAR (256) NULL, [LoweredEmail] NVARCHAR (256) NULL, [PasswordQuestion] NVARCHAR (256) NULL, [PasswordAnswer] NVARCHAR (128) NULL, [IsApproved] BIT NOT NULL, [IsLockedOut] BIT NOT NULL, [CreateDate] DATETIME2 NOT NULL, [LastLoginDate] DATETIME2 NOT NULL, [LastPasswordChangedDate] DATETIME2 NOT NULL, [LastLockoutDate] DATETIME2 NOT NULL, [FailedPasswordAttemptCount] INT NOT NULL, [FailedPasswordAttemptWindowStart] DATETIME2 NOT NULL, [FailedPasswordAnswerAttemptCount] INT NOT NULL, [FailedPasswordAnswerAttemptWindowStart] DATETIME2 NOT NULL, [Comment] NTEXT NULL, [Profile_Birthday] DateTime NULL, [Profile_Blog] NVARCHAR (255) NULL, [Profile_Gender] INT NULL, [Profile_GoogleId] NVARCHAR (255) NULL, [Profile_Homepage] NVARCHAR (255) NULL, [Profile_Facebook] NVARCHAR (400) NULL, [Profile_FacebookId] NVARCHAR (400) NULL, [Profile_Twitter] NVARCHAR (400) NULL, [Profile_TwitterId] NVARCHAR (400) NULL, [Profile_Interests] NVARCHAR (400) NULL, [Profile_Location] NVARCHAR (255) NULL, [Profile_Country] NVARCHAR (2) NULL, [Profile_Region] NVARCHAR (255) NULL, [Profile_City] NVARCHAR (255) NULL, [Profile_Occupation] NVARCHAR (400) NULL, [Profile_RealName] NVARCHAR (255) NULL, [Profile_Skype] NVARCHAR (255) NULL, [Profile_XMPP] NVARCHAR (255) NULL CONSTRAINT [PK_dbo.AspNetUsers] PRIMARY KEY CLUSTERED ([Id] ASC) /*FOREIGN KEY ([ApplicationId]) REFERENCES [dbo].[aspnet_Applications] ([ApplicationId]),*/ );] YAF.Types.Extensions.Data.c__DisplayClass14_0.b__2(String sql) +533 System.Collections.Generic.List`1.ForEach(Action`1 action) +101 YAF.Types.Extensions.Data.IDbAccessExtensions.SystemInitializeExecuteScripts(IDbAccess dbAccess, String script, String scriptFile, Int32 timeOut) +503 YAF.Core.Services.UpgradeService.ExecuteScript(String scriptFile) +150 System.Collections.Generic.List`1.ForEach(Action`1 action) +101 YAF.Core.Services.UpgradeService.Upgrade() +512 YAF.Core.Services.Startup.StartupInitializeDb.RunService() +370 YAF.Core.Services.Startup.BaseStartupService.Run() +37 System.Collections.Generic.List`1.ForEach(Action`1 action) +101 YAF.Core.Extensions.IHaveServiceLocatorExtensions.RunStartupServices(IHaveServiceLocator serviceLocator) +480 YAF.Core.Context.YafHttpApplication.Session_Start(Object sender, EventArgs e) +18 System.Web.SessionState.SessionStateModule.CompleteAcquireState() +375 System.Web.SessionState.SessionStateModule.BeginAcquireState(Object source, EventArgs e, AsyncCallback cb, Object extraData) +1257 System.Web.AsyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +703 System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step) +75 System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +158

tha_watcha
  • tha_watcha
  • 100% (Exalted)
  • YAF.NET Project Lead 🤴 YAF Version: 3.0.3
3 months ago
Originally Posted by: rainbow77 

Now this erro:

ALTER TABLE DROP COLUMN failed because column 'MembershipAppName' does not exist in table 'yaf_Board'.
 



Thats odd that should not happen...

Quote:

if I try again:



try to remove the create table script remove the lines...

CREATE TABLE [{databaseOwner}].[{objectQualifier}AspNetUsers](
    [Id]            NVARCHAR (128) NOT NULL,
    [UserName]      NVARCHAR (MAX) NULL,
    [PasswordHash]  NVARCHAR (MAX) NULL,
    [SecurityStamp] NVARCHAR (MAX) NULL,
    [EmailConfirmed]       BIT            NOT NULL,
    [PhoneNumber]          NVARCHAR (MAX) NULL,
    [PhoneNumberConfirmed] BIT            NOT NULL,
    [TwoFactorEnabled]     BIT            NOT NULL,
    [LockoutEndDateUtc]    DATETIME       NULL,
    [LockoutEnabled]       BIT            NOT NULL,
    [AccessFailedCount]    INT            NOT NULL,
    [ApplicationId]                          UNIQUEIDENTIFIER NOT NULL,
    [LegacyPasswordHash]  NVARCHAR (MAX) NULL,
    [LoweredUserName]  NVARCHAR (256)   NOT NULL,
    [MobileAlias]      NVARCHAR (16)    DEFAULT (NULL) NULL,
    [IsAnonymous]      BIT              DEFAULT ((0)) NOT NULL,
    [LastActivityDate] DATETIME2         NOT NULL,
    [MobilePIN]                              NVARCHAR (16)    NULL,
    [Email]                                  NVARCHAR (256)   NULL,
    [LoweredEmail]                           NVARCHAR (256)   NULL,
    [PasswordQuestion]                       NVARCHAR (256)   NULL,
    [PasswordAnswer]                         NVARCHAR (128)   NULL,
    [IsApproved]                             BIT              NOT NULL,
    [IsLockedOut]                            BIT              NOT NULL,
    [CreateDate]                             DATETIME2               NOT NULL,
    [LastLoginDate]                          DATETIME2         NOT NULL,
    [LastPasswordChangedDate]                DATETIME2         NOT NULL,
    [LastLockoutDate]                        DATETIME2         NOT NULL,
    [FailedPasswordAttemptCount]             INT              NOT NULL,
    [FailedPasswordAttemptWindowStart]       DATETIME2         NOT NULL,
    [FailedPasswordAnswerAttemptCount]       INT              NOT NULL,
    [FailedPasswordAnswerAttemptWindowStart] DATETIME2         NOT NULL,
    [Comment]                                NTEXT            NULL,
    [Profile_Birthday] DateTime NULL,
    [Profile_Blog] NVARCHAR (255) NULL,
    [Profile_Gender] INT NULL,
    [Profile_GoogleId] NVARCHAR (255) NULL,
    [Profile_Homepage] NVARCHAR (255) NULL,
    [Profile_Facebook] NVARCHAR (400) NULL,
    [Profile_FacebookId] NVARCHAR (400) NULL,
    [Profile_Twitter] NVARCHAR (400) NULL,
    [Profile_TwitterId] NVARCHAR (400) NULL,
    [Profile_Interests] NVARCHAR (400) NULL,
    [Profile_Location] NVARCHAR (255) NULL,
    [Profile_Country] NVARCHAR (2) NULL,
    [Profile_Region] NVARCHAR (255) NULL,
    [Profile_City] NVARCHAR (255) NULL,
    [Profile_Occupation] NVARCHAR (400) NULL,
    [Profile_RealName] NVARCHAR (255) NULL,
    [Profile_Skype] NVARCHAR (255) NULL,
    [Profile_XMPP] NVARCHAR (255) NULL
    CONSTRAINT [PK_{databaseOwner}.AspNetUsers] PRIMARY KEY CLUSTERED ([Id] ASC)
    /*FOREIGN KEY ([ApplicationId]) REFERENCES [{databaseOwner}].[aspnet_Applications] ([ApplicationId]),*/
);

GO

from the file install/mssql/upgrade/identity/upgrade.sql

 
rainbow77
  • rainbow77
  • 65.8% (Friendly)
  • YAF Forumling Topic Starter YAF Version: 1.9.301
3 months ago
Now:
Quote:

FILE:
install/mssql/upgrade/identity/upgrade.sql

ERROR:
There is already an object named 'yaf_AspNetRoles' in the database.

STATEMENT:
CREATE TABLE [dbo].[yaf_AspNetRoles](
 [Id] [nvarchar](128) NOT NULL,
 [Name] [nvarchar](256) NOT NULL,
CONSTRAINT [PK_AspNetRoles] PRIMARY KEY CLUSTERED
(
 [Id] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON)
)



can i delete this too?
rainbow77
  • rainbow77
  • 65.8% (Friendly)
  • YAF Forumling Topic Starter YAF Version: 1.9.301
3 months ago
I removed the lines where the "Create" error gave me and now it gives me this:
Quote:

FILE:
install/mssql/upgrade/identity/upgrade.sql

ERROR:
Violation of PRIMARY KEY constraint 'PK_AspNetRoles'. Cannot insert duplicate key in object 'dbo.yaf_AspNetRoles'. The duplicate key value is (05904DA8-3C2E-42BC-88CB-50E7DB9B62F4).
The statement has been terminated.

STATEMENT:
INSERT INTO [dbo].[yaf_AspNetRoles](Id,Name)
SELECT RoleId,RoleName
FROM [dbo].[yaf_prov_Role]

tha_watcha
  • tha_watcha
  • 100% (Exalted)
  • YAF.NET Project Lead 🤴 YAF Version: 3.0.3
3 months ago
i think you can remove the entire content of the upgrade.sql file.
rainbow77
  • rainbow77
  • 65.8% (Friendly)
  • YAF Forumling Topic Starter YAF Version: 1.9.301
3 months ago
and after removing other insert and create rows this is the error:
Quote:

Invalid column name 'DarkMode'.
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: Invalid column name 'DarkMode'.

rainbow77
  • rainbow77
  • 65.8% (Friendly)
  • YAF Forumling Topic Starter YAF Version: 1.9.301
3 months ago
I do.
the error is column Darkmode
tha_watcha
  • tha_watcha
  • 100% (Exalted)
  • YAF.NET Project Lead 🤴 YAF Version: 3.0.3
3 months ago
Thats seems to be a bug. I updated the release

https://github.com/YAFNET/YAFNET/releases/download/v3.1.14/YAF.SqlServer-v3.1.14-Upgrade.zip 

Download the upgrade package and then replace only the dlls from the bin folder.
rainbow77
  • rainbow77
  • 65.8% (Friendly)
  • YAF Forumling Topic Starter YAF Version: 1.9.301
3 months ago
Works!!!!!!!🤩
Thank you
tha_watcha
  • tha_watcha
  • 100% (Exalted)
  • YAF.NET Project Lead 🤴 YAF Version: 3.0.3
3 months ago
On more change disable debug mode, otherwise the javascripts dont work

change the line in the web.config from...

<compilation debug="true" targetFramework="4.8" optimizeCompilations="false">

to
<compilation debug="false" targetFramework="4.8" optimizeCompilations="false">
 
rainbow77
  • rainbow77
  • 65.8% (Friendly)
  • YAF Forumling Topic Starter YAF Version: 1.9.301
3 months ago

Everything seems to work now.
The only thing is the look and colors.
They are different than the test forum or even this forum.
Depends on what?
tha_watcha
  • tha_watcha
  • 100% (Exalted)
  • YAF.NET Project Lead 🤴 YAF Version: 3.0.3
3 months ago
It depends on which theme you are using. As far as I can see you use the standard yaf theme, the same as the test forum.
rainbow77
  • rainbow77
  • 65.8% (Friendly)
  • YAF Forumling Topic Starter YAF Version: 1.9.301
3 months ago
Yes, so I must have some css that interferes with the forum one.
I'm trying to figure out where I can fix
tha_watcha
  • tha_watcha
  • 100% (Exalted)
  • YAF.NET Project Lead 🤴 YAF Version: 3.0.3
3 months ago
Originally Posted by: rainbow77 

Yes, so I must have some css that interferes with the forum one.
I'm trying to figure out where I can fix



Can you point to the differences? your forum and the test forum are completely identical. I don't see any differences.
rainbow77
  • rainbow77
  • 65.8% (Friendly)
  • YAF Forumling Topic Starter YAF Version: 1.9.301
3 months ago
UserPostedImage

the fonts are black and the page goes from left to right instead of being centered
YAF Logo Copyright © YetAnotherForum.NET & Ingo Herbote. All rights reserved
About Us

The YAF.NET is an open source .NET forum project. YAF.NET is supported by an team of international developers who are build community by building community software.

Powered by Resharper Donate with PayPal button