Database error when adding single version product

Posted By mike Tue 10 Aug 2010
Rated stars based on 1 vote.
Add to Favorites2
Author Message
mike
 Posted Tue 10 Aug 2010
Supreme Being

Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)

Group: Awaiting Activation
Last Active: Thu 25 Oct 2012
Posts: 15, Visits: 210
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
Medz
 Posted Tue 10 Aug 2010
Kartris Expert

Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)

Group: Administrators
Last Active: Tue 3 Dec 2013
Posts: 99, Visits: 1,400
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"/>
Mohammad
 Posted Tue 10 Aug 2010
Kartris Expert

Kartris Expert - (78,909 reputation)Kartris Expert - (78,909 reputation)Kartris Expert - (78,909 reputation)Kartris Expert - (78,909 reputation)Kartris Expert - (78,909 reputation)Kartris Expert - (78,909 reputation)Kartris Expert - (78,909 reputation)Kartris Expert - (78,909 reputation)Kartris Expert - (78,909 reputation)

Group: Administrators
Last Active: Sun 27 Sep 2015
Posts: 115, Visits: 706
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
Mon 27 Sep 2010 by Paul
mike
 Posted Tue 10 Aug 2010
Supreme Being

Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)

Group: Awaiting Activation
Last Active: Thu 25 Oct 2012
Posts: 15, Visits: 210
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
Medz
 Posted Fri 13 Aug 2010
Kartris Expert

Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)

Group: Administrators
Last Active: Tue 3 Dec 2013
Posts: 99, Visits: 1,400
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
mike
 Posted Thu 19 Aug 2010
Supreme Being

Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)

Group: Awaiting Activation
Last Active: Thu 25 Oct 2012
Posts: 15, Visits: 210
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
mike
 Posted Thu 19 Aug 2010
Supreme Being

Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)Supreme Being - (12,037 reputation)

Group: Awaiting Activation
Last Active: Thu 25 Oct 2012
Posts: 15, Visits: 210
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
Medz
 Posted Thu 19 Aug 2010
Kartris Expert

Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)Kartris Expert - (66,032 reputation)

Group: Administrators
Last Active: Tue 3 Dec 2013
Posts: 99, Visits: 1,400
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
smgentry
 Posted Sun 19 Sep 2010
Supreme Being

Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)

Group: Forum Members
Last Active: Thu 23 Sep 2010
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!
smgentry
 Posted Mon 20 Sep 2010
Supreme Being

Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)Supreme Being - (1,470 reputation)

Group: Forum Members
Last Active: Thu 23 Sep 2010
Posts: 2, Visits: 11
Medz,

The provided .dll fixed my problem, thanks!

Similar Topics

Expand / Collapse

Reading This Topic

Expand / Collapse

Back To Top