an ASP.NET Open Source CMS & eCommerce platform
Search:
Skip Navigation LinksHome > DotShoppingCart Forums > Support > Using DotShoppingCart > Coupon generation error
Last Post 1/15/2010 9:56:40 PM By lukezy. 4 replies.
1/14/2010 2:44:22 PM
jsduggan
Posts: 52
Joined: 3/19/2009
Coupon generation error
Every time I try to generate a coupon using a custom name (not the random code created by DSC) I get the below error.  DSC will only generate the coupon if I leave the name field blank and allow the system to generate one automatically.  I then tried to go in and edit the name of the coupon, but it also errored out.  I remember this being an issue with v3.1 as well.  Is this a bug or something that can be resolved through configuration settings? Thanks.
 
Timestamp: 1/14/2010 10:42:07 PM
Message: HandlingInstanceID: 291b763a-022e-4067-8a3c-10c63451a281
An exception of type 'System.Web.HttpUnhandledException' occurred and was caught.
---------------------------------------------------------------------------------
01/14/2010 14:42:07
Type : System.Web.HttpUnhandledException, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
Message : Exception of type 'System.Web.HttpUnhandledException' was thrown.
Source : System.Web
Help link :
ErrorCode : -2147467259
Data : System.Collections.ListDictionaryInternal
TargetSite : Boolean HandleError(System.Exception)
Stack Trace : at System.Web.UI.Page.HandleError(Exception e)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest()
at System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context)
at System.Web.UI.Page.ProcessRequest(HttpContext context)
at ASP.admin_promotion_coupon_aspx.ProcessRequest(HttpContext context) in c:\Windows\Microsoft.NET\Framework\v2.0.50727\Temporary <a href="http://ASP.NET" target="_blank">ASP.NET Files\root\45d6a688\a3507d1d\App_Web_2yrwo-ro.2.cs:line 0
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

Additional Info:

MachineName : WIN2008STD
TimeStamp : 1/14/2010 10:42:07 PM
FullName : Microsoft.Practices.EnterpriseLibrary.ExceptionHandling, Version=4.1.0.0, Culture=neutral, PublicKeyToken=null
AppDomainName : /LM/W3SVC/1/ROOT-1-129079786528447060
ThreadIdentity : admin
WindowsIdentity : NT AUTHORITY\NETWORK SERVICE
Inner Exception
---------------
Type : System.Data.SqlClient.SqlException, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
Message : String or binary data would be truncated.
The statement has been terminated.
Source : .Net SqlClient Data Provider
Help link :
Errors : System.Data.SqlClient.SqlErrorCollection
Class : 16
LineNumber : 1
Number : 8152
Procedure :
Server : .\SQLExpress
State : 14
ErrorCode : -2146232060
Data : System.Collections.ListDictionaryInternal
TargetSite : Void OnError(System.Data.SqlClient.SqlException, Boolean)
Stack Trace : at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
at System.Data.SqlClient.SqlInternalConnection.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.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.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at System.Data.Linq.SqlClient.SqlProvider.Execute(Expression query, QueryInfo queryInfo, IObjectReaderFactory factory, Object[] parentArgs, Object[] userArgs, ICompiledSubQuery[] subQueries, Object lastResult)
at System.Data.Linq.SqlClient.SqlProvider.ExecuteAll(Expression query, QueryInfo[] queryInfos, IObjectReaderFactory factory, Object[] userArguments, ICompiledSubQuery[] subQueries)
at System.Data.Linq.SqlClient.SqlProvider.System.Data.Linq.Provider.IProvider.Execute(Expression query)
at System.Data.Linq.ChangeDirector.StandardChangeDirector.DynamicUpdate(TrackedObject item)
at System.Data.Linq.ChangeDirector.StandardChangeDirector.Update(TrackedObject item)
at System.Data.Linq.ChangeProcessor.SubmitChanges(ConflictMode failureMode)
at System.Data.Linq.DataContext.SubmitChanges(ConflictMode failureMode)
at System.Data.Linq.DataContext.SubmitChanges()
at System.Web.UI.WebControls.LinqToSqlWrapper.SubmitChanges(DataContext dataContext)
at System.Web.UI.WebControls.LinqDataSourceView.UpdateDataObject(Object dataContext, Object table, Object oldDataObject, Object newDataObject)
at System.Web.UI.WebControls.LinqDataSourceView.ExecuteUpdate(IDictionary keys, IDictionary values, IDictionary oldValues)
at System.Web.UI.DataSourceView.Update(IDictionary keys, IDictionary values, IDictionary oldValues, DataSourceViewOperationCallback callback)
at System.Web.UI.WebControls.DetailsView.HandleUpdate(String commandArg, Boolean causesValidation)
at System.Web.UI.WebControls.DetailsView.HandleEvent(EventArgs e, Boolean causesValidation, String validationGroup)
at System.Web.UI.WebControls.DetailsView.OnBubbleEvent(Object source, EventArgs e)
at System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args)
at System.Web.UI.WebControls.DetailsViewRow.OnBubbleEvent(Object source, EventArgs e)
at System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args)
at System.Web.UI.WebControls.Button.OnCommand(CommandEventArgs e)
at System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument)
at System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument)
at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)
at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)


Category: General
Priority: 0
EventId: 100
Severity: Error
Title:Enterprise Library Exception Handling
Machine: WIN2008STD
Application Domain: /LM/W3SVC/1/ROOT-1-129079786528447060
Process Id: 6044
Process Name: c:\windows\system32\inetsrv\w3wp.exe
Win32 Thread Id: 976
Thread Name:
Extended Properties: Url - <a href="https://www.portolacoffee.com/Admin/Promotion/Coupon.aspx" target="_blank">https://www.portolacoffee.com/Admin/Promotion/Coupon.aspx
RawUrl - /Admin/Promotion/Coupon.aspx
UseAgent - Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.2)
UrlReferrer - <a href="https://www.portolacoffee.com/Admin/Promotion/Coupon.aspx" target="_blank">https://www.portolacoffee.com/Admin/Promotion/Coupon.aspx
IPAddress - 75.55.253.233
1/14/2010 2:51:31 PM
jsduggan
Posts: 52
Joined: 3/19/2009
Re: Coupon generation error
Is there a character limit for the coupon name field?  If so, what is it and can it be extended?
 
Thanks.
1/15/2010 5:43:52 PM
lukezy
Posts: 2109
Joined: 6/12/2007
Location:WA, US
Re: Coupon generation error
This is defined by the table schema. You can increase the column size in the DSC_Coupon table and also change the related store procedures.
DotShoppingCart Staff
1/15/2010 7:23:41 PM
jsduggan
Posts: 52
Joined: 3/19/2009
Re: Coupon generation error
 Luke,
By chance do you know what the character limit is?  I would rather just try to keep within the limit than going through the hassle of changing it.  Thank you.
1/15/2010 9:56:40 PM
lukezy
Posts: 2109
Joined: 6/12/2007
Location:WA, US
Re: Coupon generation error
It's 12 chars.
DotShoppingCart Staff