Database error when adding single version product

Author Message
 Posted 10 August 2010 09:37
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Awaiting Activation
Last Login: 15 November 2011 16:51
Posts: 14, Visits: 209
Hello there,

I've been having a bit of trouble adding products into my Kartris install, and I was wondering if anyone could help. I keep getting a 'general database error' when attempting to add single version products (though not when adding multiple version or options products). I tried it on a separate fresh install as well and seemed to have the same problem. The error log entry is below:

-----------------------------------------------------------------------------
>>    VersionsBLL._AddNewVersionAsSingle
-----------------------------------------------------------------------------
>>    System.Data.SqlClient.SqlException
>>    10/08/2010 09:05:30
>>    81.149.11.65
>>    CUSTOM MESSAGE:
Database Error: A general error has occurred.
>>    NUMBER:-2
>>    MESSAGE:
Timeout expired.  The timeout period elapsed prior to completion of the operation or the server is not responding.
>>    STACK:
   at System.Data.SqlClient.SqlConnection.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.SqlDataReader.ConsumeMetaData()
   at System.Data.SqlClient.SqlDataReader.get_MetaData()
   at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
   at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
   at System.Data.SqlClient.SqlCommand.ExecuteScalar()
   at kartrisVersionsDataTableAdapters.VersionsTblAdptr._TotalVersions()
   at VersionsBLL._ExceedLimit(Int32 intToBeAdded)
   at VersionsBLL._AddNewVersionAsSingle(DataTable tblElements, String strCodeNumber, Int32 intProductID, Int16 intCustomerGrp, SqlConnection sqlConn, SqlTransaction savePoint, String& strMsg)
==================================================


-----------------------------------------------------------------------------
>>    ProductsBLL._AddProduct
-----------------------------------------------------------------------------
>>    System.ApplicationException
>>    10/08/2010 09:05:30
>>    81.149.11.65
>>    CUSTOM MESSAGE:
Database Error: A general error has occurred.Error occurred while processing the operation.
>>    MESSAGE:
Error occurred while processing the operation.
>>    STACK:
   at ProductsBLL._AddProduct(DataTable ptblElements, String pParentsList, Int32& pProductID, Boolean pLive, Byte pFeatured, String pOrderVersionsBy, Char pVersionsSortDirection, Char pReviews, Char pVersionDisplayType, Int32 pSupplier, Char pProductType, Int32 pCustomerGroupID, String& strMsg)
==================================================

The point of failure appears to be 'AddNewVersionAsSingle', which makes sense given the problem I'm having.

Many thanks in advance,
Mike


Tags:
Post #63
Add to Twitter Add to Facebook
 Posted 10 August 2010 12:01
Kartris Expert

Kartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris Expert

Group: Administrators
Last Login: 15 May 2012 06:29
Posts: 51, Visits: 1,160
Hi Mike, it looks like you're getting timeout errors which happen when your database server doesn't responds to queries fast enough. You can you try to add ";Connect Timeout=30" to your connection string in the web.config and see if it helps.

eg.

<add name="KartrisSQLConnection" connectionString="Data Source=YOURSERVERNAME;Initial Catalog=YOURDATABASENAME;User ID=YOURUSERNAME;Password=YOURPASSWORD;Connect Timeout=30" providerName="System.Data.SqlClient" />

or if you're using integration authentication ->

<add name="KartrisSQLConnection" connectionString="Data Source=localhost;Database=kartrisSQL;Integrated Security=True;connect timeout=30" providerName="System.Data.SqlClient"/>


Tags:
Post #64
Add to Twitter Add to Facebook
 Posted 10 August 2010 12:19
Kartris Expert

Kartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris Expert

Group: Administrators
Last Login: 2 days ago @ 02:22
Posts: 113, Visits: 654
Hello Mike,

You are right, adding single product causes general error sometimes, but the product itself will be added correctly under the specified category - If its not timed out -

The fix should be with the new release in the next couple of days.

Mohammad


Tags:

Edited: 27 September 2010 07:53 by Paul
Post #65
Add to Twitter Add to Facebook
 Posted 10 August 2010 12:51
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Awaiting Activation
Last Login: 15 November 2011 16:51
Posts: 14, Visits: 209
Hi Medz and Mohammad,

thanks a lot for your replies. I've tried adding the 'connect timeout'setting to the connection string as you suggested, but it doesn't seemto have helped. I've taken it as high as 120, the error messageremains as before. I've timed how long it took for the error message toappear after clicking 'Save', and it came out (consistently) as 31 seconds. The product isn't added when I receive the error.

Thanks,
Mike
Post #66
Add to Twitter Add to Facebook
 Posted 13 August 2010 04:50
Kartris Expert

Kartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris Expert

Group: Administrators
Last Login: 15 May 2012 06:29
Posts: 51, Visits: 1,160
Hi Mike, v1.1009 is now up. It includes the fix to the issue when adding single version products.

http://www.kartris.com/Downloads/kartris1_1009_WPI.zip

Cheers

Medz
Post #71
Add to Twitter Add to Facebook
 Posted 19 August 2010 11:44
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Awaiting Activation
Last Login: 15 November 2011 16:51
Posts: 14, Visits: 209
Hello again,
Just an update for you all - I've now had a chance to install the latest version (1.1009), and I'm afraid I still seem to be having the same problem! This is with a completely fresh install (with no customization, and completely separate from my previous one). The error (and error log entry) is exactly the same as before.

I'd appreciate it if you could offer any guidance on where to look for issues (if there are any server settings which could be wrong, for example), so I can give you guys whatever information you need to get this sorted ASAP.

Thanks again in advance,
Michael
Post #79
Add to Twitter Add to Facebook
 Posted 19 August 2010 14:45
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Awaiting Activation
Last Login: 15 November 2011 16:51
Posts: 14, Visits: 209
Success!
Overwrote the dll with the new one you provided, and it appears to be working now. Thanks a lot for sorting this out, and if I find any other bugs then I'll let you know Wink

Cheers,
Mike
Post #81
Add to Twitter Add to Facebook
 Posted 19 August 2010 20:18
Kartris Expert

Kartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris ExpertKartris Expert

Group: Administrators
Last Login: 15 May 2012 06:29
Posts: 51, Visits: 1,160
Great! Thanks for letting us know. I'll incorporate the fix in the 1.1011 build. Thanks for all your input in this.

Regards,

Medz
Post #82
Add to Twitter Add to Facebook
 Posted 19 September 2010 21:23
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Forum Members
Last Login: 23 September 2010 02:21
Posts: 2, Visits: 11
I am also having this same issue. Could you tell me what you did to finally resolve this? It looks like you installed a new dll file over your old one. Was that with the 1.1009 version or a newer version?

Any help would be much appreciated.

Thanks!
Post #107
Add to Twitter Add to Facebook
 Posted 20 September 2010 17:45
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Forum Members
Last Login: 23 September 2010 02:21
Posts: 2, Visits: 11
Medz,

The provided .dll fixed my problem, thanks!
Post #108
Add to Twitter Add to Facebook


Similar Topics

Expand / Collapse

Reading This Topic

Expand / Collapse