Anry131
  •  Anry131
  • 51.8% (Neutral)
  • YAF Forumling Topic Starter
2009-05-03T08:14:28Z
HI. I have lateset version 1.9.3.RC2. And i try to integrate YAF in my existing website.
Here part of my web.config file:

   <roleManager enabled="true" defaultProvider="YafRoleProvider">
            <providers>
                <clear/>
                    <add connectionStringName="yafnet" applicationName="YetAnotherForum" name="YafRoleProvider" type="YAF.Providers.Roles.YafRoleProvider"/>
            </providers>
        </roleManager>
        <membership defaultProvider="YafMembershipProvider" hashAlgorithmType="SHA1">
            <providers>
                <clear/>
                <add connectionStringName="yafnet" applicationName="YetAnotherForum" name="YafMembershipProvider" requiresUniqueEmail="true" useSalt="true" type="YAF.Providers.Membership.YafMembershipProvider"/>
            </providers>
        </membership>
        <profile enabled="true" defaultProvider="YafProfileProvider" inherits="YAF.Classes.Utils.YafUserProfile">
            <providers>
                <clear/>
                    <add connectionStringName="yafnet" applicationName="YetAnotherForum" name="YafProfileProvider" type="YAF.Providers.Profile.YafProfileProvider"/>
            </providers>
        </profile>

And i have very ineresting and strange error: when I try to be authorised from the main page of a site I receive this error:

Server Error in '/' Application.
Could not find stored procedure 'prov_getuser'.
Exception Details: System.Data.SqlClient.SqlException: Could not find stored procedure 'prov_getuser'.
Stack Trace: 
[SqlException (0x80131904): Could not find stored procedure 'prov_getuser'.]
   System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) +925466
   System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) +800118
   System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) +186
   System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) +1932
   System.Data.SqlClient.SqlDataReader.ConsumeMetaData() +31
   System.Data.SqlClient.SqlDataReader.get_MetaData() +62
   System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString) +297
   System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async) +1005
   System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result) +132
   System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) +32
   System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) +122
   System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior) +12
   System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior) +7
   System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +141
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +137
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet) +86
   YAF.Classes.Data.DBAccess.GetDatasetBasic(SqlCommand cmd, Boolean transaction) +410
   YAF.Classes.Data.DBAccess.GetData(SqlCommand cmd, Boolean transaction) +63
   YAF.Classes.Data.DBAccess.GetData(SqlCommand cmd) +7
   YAF.Providers.Membership.DB.GetUserPasswordInfo(String appName, String username, Boolean updateUser) +180
   YAF.Providers.Membership.UserPasswordInfo.CreateInstanceFromDB(String appName, String username, Boolean updateUser, Boolean useSalt) +19
   YAF.Providers.Membership.YafMembershipProvider.ValidateUser(String username, String password) +29
   System.Web.UI.WebControls.Login.OnAuthenticate(AuthenticateEventArgs e) +160
   System.Web.UI.WebControls.Login.AttemptLogin() +105
   System.Web.UI.WebControls.Login.OnBubbleEvent(Object source, EventArgs e) +99
   System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +35
   System.Web.UI.WebControls.Button.OnCommand(CommandEventArgs e) +115
   System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +163
   System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +7
   System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +11
   System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1746

But!!! But if somebody loads page with a forum, the error passes. And I can be authorised from the main page of site, while application is runing. This repeats every time when application life cycle is comes to end, and it is restarted.

Please help me!!
Sponsor
Mek
  •  Mek
  • 100% (Exalted)
  • YAF Developer
2009-05-03T10:08:09Z
Sounds like your using our provider in your main site; but you are not including the App.config in your main site web.config so the provider doesn't know your database prefix i.e. in a standard YAF install it will prefix YAF to make YAF_Prov_Getuser.

UserPostedImage 

"It's a case of RTFM.. the only problem being we don't have a manual!"

When I post FP:Mek in a topic, I'm leaving my footprint there so I can track it once I get into coding/supporting. (Yes I stole this off Ederon 🙂 )
Anry131
  •  Anry131
  • 51.8% (Neutral)
  • YAF Forumling Topic Starter
2009-05-04T00:32:28Z
Thank for u fast answer. I really have not included app.config in my site web.config(( Now the problem is solved.

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

Project Twitter Updates

Copyright © YetAnotherForum.NET & Ingo Herbote. All rights reserved