YAFLogo

wakeboardtime
14 years ago
Hi all,

I get this error when trying to select "Watch this topic and receive notification via e-mail." Any clues?

Server Error in '/' Application.

--------------------------------------------------------------------------------

The INSERT statement conflicted with the FOREIGN KEY constraint "FK_yaf_WatchTopic_yaf_Topic". The conflict occurred in database "yaf", table "dbo.yaf_Topic", column 'TopicID'.

The statement has been terminated.

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: The INSERT statement conflicted with the FOREIGN KEY constraint "FK_yaf_WatchTopic_yaf_Topic". The conflict occurred in database "yaf", table "dbo.yaf_Topic", column 'TopicID'.

The statement has been terminated.

Source Error:

Line 784: {

Line 785: // subscribe to this forum

Line 786: DB.watchtopic_add(userId, topicId);

Line 787: }

Line 788: }

Source File: c:\Inetpub\vhosts\test.wakeboardtime.com\httpdocs\pages\postmessage.ascx.cs Line: 786

Stack Trace:

[SqlException (0x80131904): The INSERT statement conflicted with the FOREIGN KEY constraint "FK_yaf_WatchTopic_yaf_Topic". The conflict occurred in database "yaf", table "dbo.yaf_Topic", column 'TopicID'.

The statement has been terminated.]

System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) +1948826

System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) +4844747

System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) +194

System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) +2392

System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString) +204

System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async) +954

System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result) +162

System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe) +175

System.Data.SqlClient.SqlCommand.ExecuteNonQuery() +137

YAF.Classes.Data.YafDBAccess.ExecuteNonQuery(SqlCommand cmd, Boolean transaction) in C:\projects\wbt\trunk\yafsrc\YAF.Classes\YAF.Classes.Data\YafDBAccess.cs:403

YAF.Classes.Data.DB.watchtopic_add(Object userID, Object topicID) in C:\projects\wbt\trunk\yafsrc\YAF.Classes\YAF.Classes.Data\DB.cs:8385

YAF.Pages.postmessage.WatchTopic(Int32 userId, Int32 topicId) in c:\Inetpub\vhosts\test.wakeboardtime.com\httpdocs\pages\postmessage.ascx.cs:786

YAF.Pages.postmessage.UpdateWatchTopic(Int32 userId, Int32 topicId) in c:\Inetpub\vhosts\test.wakeboardtime.com\httpdocs\pages\postmessage.ascx.cs:773

YAF.Pages.postmessage.PostReplyHandleNewPost() in c:\Inetpub\vhosts\test.wakeboardtime.com\httpdocs\pages\postmessage.ascx.cs:708

YAF.Pages.postmessage.PostReply_Click(Object sender, EventArgs e) in c:\Inetpub\vhosts\test.wakeboardtime.com\httpdocs\pages\postmessage.ascx.cs:560

YAF.Controls.ThemeButton.OnClick(EventArgs e) in C:\projects\wbt\trunk\yafsrc\YAF.Controls\ThemeButton.cs:415

YAF.Controls.ThemeButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) in C:\projects\wbt\trunk\yafsrc\YAF.Controls\ThemeButton.cs:273

System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13

System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +175

System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565

--------------------------------------------------------------------------------

Version Information: Microsoft .NET Framework Version:2.0.50727.3053; ASP.NET Version:2.0.50727.3053

Sponsor
LaurenceB
14 years ago
what version of YAF??
wakeboardtime
14 years ago
YetAnotherForum.NET version 1.9.4 RC2 (Date: 1/12/2010).

(must have taken the tip from SourceForge)

Everything else works great so I'd like to keep this if possible.

LaurenceB
14 years ago
supposedly rc2 is kinda unstable I am using rc1 right now and have no problems with it so far in extensive single testing so I don't know if this is just a rc2 problem or a rc1 I am kinda leaning towards just rc2
wakeboardtime
14 years ago
:cry: Oh, well. I'll have to try dropping down to RC1. I'll let you know what happens.

bbobb
  • bbobb
  • 100% (Exalted)
  • YAF Developer
ani07in
  • ani07in
  • 51.2% (Neutral)
  • YAF Forumling
14 years ago

Hi all,

I get this error when trying to select "Watch this topic and receive notification via e-mail." Any clues?

Server Error in '/' Application.

--------------------------------------------------------------------------------

The INSERT statement conflicted with the FOREIGN KEY constraint "FK_yaf_WatchTopic_yaf_Topic". The conflict occurred in database "yaf", table "dbo.yaf_Topic", column 'TopicID'.

The statement has been terminated.

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: The INSERT statement conflicted with the FOREIGN KEY constraint "FK_yaf_WatchTopic_yaf_Topic". The conflict occurred in database "yaf", table "dbo.yaf_Topic", column 'TopicID'.

The statement has been terminated.

Source Error:

Line 784: {

Line 785: // subscribe to this forum

Line 786: DB.watchtopic_add(userId, topicId);

Line 787: }

Line 788: }

Source File: c:\Inetpub\vhosts\test.wakeboardtime.com\httpdocs\pages\postmessage.ascx.cs Line: 786

Stack Trace:

[SqlException (0x80131904): The INSERT statement conflicted with the FOREIGN KEY constraint "FK_yaf_WatchTopic_yaf_Topic". The conflict occurred in database "yaf", table "dbo.yaf_Topic", column 'TopicID'.

The statement has been terminated.]

System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) +1948826

System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) +4844747

System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) +194

System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) +2392

System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString) +204

System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async) +954

System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result) +162

System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe) +175

System.Data.SqlClient.SqlCommand.ExecuteNonQuery() +137

YAF.Classes.Data.YafDBAccess.ExecuteNonQuery(SqlCommand cmd, Boolean transaction) in C:\projects\wbt\trunk\yafsrc\YAF.Classes\YAF.Classes.Data\YafDBAccess.cs:403

YAF.Classes.Data.DB.watchtopic_add(Object userID, Object topicID) in C:\projects\wbt\trunk\yafsrc\YAF.Classes\YAF.Classes.Data\DB.cs:8385

YAF.Pages.postmessage.WatchTopic(Int32 userId, Int32 topicId) in c:\Inetpub\vhosts\test.wakeboardtime.com\httpdocs\pages\postmessage.ascx.cs:786

YAF.Pages.postmessage.UpdateWatchTopic(Int32 userId, Int32 topicId) in c:\Inetpub\vhosts\test.wakeboardtime.com\httpdocs\pages\postmessage.ascx.cs:773

YAF.Pages.postmessage.PostReplyHandleNewPost() in c:\Inetpub\vhosts\test.wakeboardtime.com\httpdocs\pages\postmessage.ascx.cs:708

YAF.Pages.postmessage.PostReply_Click(Object sender, EventArgs e) in c:\Inetpub\vhosts\test.wakeboardtime.com\httpdocs\pages\postmessage.ascx.cs:560

YAF.Controls.ThemeButton.OnClick(EventArgs e) in C:\projects\wbt\trunk\yafsrc\YAF.Controls\ThemeButton.cs:415

YAF.Controls.ThemeButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) in C:\projects\wbt\trunk\yafsrc\YAF.Controls\ThemeButton.cs:273

System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13

System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +175

System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565

--------------------------------------------------------------------------------

Version Information: Microsoft .NET Framework Version:2.0.50727.3053; ASP.NET Version:2.0.50727.3053

what is quote wrote:

ani07in
  • ani07in
  • 51.2% (Neutral)
  • YAF Forumling
14 years ago
testing what ius quote

supposedly rc2 is kinda unstable I am using rc1 right now and have no problems with it so far in extensive single testing so I don't know if this is just a rc2 problem or a rc1 I am kinda leaning towards just rc2

LaurenceB wrote: