Consider the following scenario:
Additionally, the following error message is logged in the SQL Server error log file:
- You have a computer that is running Microsoft Commerce Server 2009.
- You configure the SearchCriteria.CategoriesClause parameter so that a CommerceQuery operation searches products across multiple categories. For example, you configure the SearchCriteria.CategoriesClause parameter by using the following syntax:
query.SearchCriteria.CategoriesClause = "[IsSearchable] = 1";
- You start the CommerceQuery operation that returns multiple Commerce Server products from multiple categories on a Commerce Server site.
Exception Details: System.ServiceModel.FaultException`1[[Microsoft.Commerce.Contracts.Faults.GeneralOperationFault, Microsoft.Commerce.Contracts, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: The operation service has encountered an error while processing the request. The error details have been logged by the service.
Source Error:
Line 49: ParameterChecker.CheckForNull(operation, "operation");
Line 50:
Line 51: return CommerceFoundationServiceAgent.operationServiveAgent.ProcessRequest(
Line 52: GetCurrentRequestContext(), operation.ToRequest());
Line 53: }
Source File: C:\CS2009\Catalog\Components\CommerceFoundationServiceAgent.cs Line: 51
Stack Trace:
[FaultException`1: The operation service has encountered an error while processing the request. The error details have been logged by the service.]
Microsoft.Commerce.Broker.OperationService.ProcessRequest(CommerceRequest request) +697
Microsoft.Commerce.Common.OperationServiceAgent.ProcessRequest(CommerceRequestContext requestContext, CommerceRequest request) +154
Microsoft.Samples.Commerce.Catalog.CommerceFoundationServiceAgent.Execute(CommerceBaseBuilder operation) in C:\CS2009\Catalog\Components\CommerceFoundationServiceAgent.cs:51
Microsoft.Samples.Commerce.Catalog.SimpleSearch.BtnSearch_Click(Object sender, EventArgs e) in C:\CS2009\Catalog\SimpleSearch.aspx.cs:76
System.Web.UI.WebControls.Button.OnClick(EventArgs e) +115
System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +140
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +29
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2981
Source Error:
Line 49: ParameterChecker.CheckForNull(operation, "operation");
Line 50:
Line 51: return CommerceFoundationServiceAgent.operationServiveAgent.ProcessRequest(
Line 52: GetCurrentRequestContext(), operation.ToRequest());
Line 53: }
Source File: C:\CS2009\Catalog\Components\CommerceFoundationServiceAgent.cs Line: 51
Stack Trace:
[FaultException`1: The operation service has encountered an error while processing the request. The error details have been logged by the service.]
Microsoft.Commerce.Broker.OperationService.ProcessRequest(CommerceRequest request) +697
Microsoft.Commerce.Common.OperationServiceAgent.ProcessRequest(CommerceRequestContext requestContext, CommerceRequest request) +154
Microsoft.Samples.Commerce.Catalog.CommerceFoundationServiceAgent.Execute(CommerceBaseBuilder operation) in C:\CS2009\Catalog\Components\CommerceFoundationServiceAgent.cs:51
Microsoft.Samples.Commerce.Catalog.SimpleSearch.BtnSearch_Click(Object sender, EventArgs e) in C:\CS2009\Catalog\SimpleSearch.aspx.cs:76
System.Web.UI.WebControls.Button.OnClick(EventArgs e) +115
System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +140
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +29
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2981
Additionally, the following error message is logged in the SQL Server error log file:
Msg 2627, Level 14, State 1, Line 1 Violation of UNIQUE KEY constraint 'UQ__CtlInv____<text>'. Cannot insert duplicate key in object 'dbo.CtlInv___CategorySearch___SortedResults__for_spid__<spid>'. The statement has been terminated.