FaultException attributeName LINQ Where ID clause
Hello and thanks for your time. I'm receiving a FaultException
AtribbuteName exception when I execute:
from primary in PrimarySet
join secondary in SecondarySet
on primary.RegisterId equals secondary.Register.Id
where secondary.Id == new Guid("0EEB1E6E-C608-E311-8AEE-984BE17C6693")
// <-- problematic where clause
select primary.BooleanField
The StackTrace I receive is:
Server stack trace:
at
System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime
operation, ProxyRpc& rpc)
at System.ServiceModel.Channels.ServiceChannel.Call(String action,
Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[]
outs, TimeSpan timeout)
at
System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage
methodCall, ProxyOperationRuntime operation)
at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage
message)
Exception rethrown at [0]:
at
System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage
reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData&
msgData, Int32 type)
at Microsoft.Xrm.Sdk.IOrganizationService.Execute(OrganizationRequest
request)
at
Microsoft.Xrm.Sdk.Client.OrganizationServiceProxy.ExecuteCore(OrganizationRequest
request)
at
Microsoft.Xrm.Sdk.Client.OrganizationServiceProxy.Execute(OrganizationRequest
request)
at
CrmLINQPadPlugin.OrganizationServiceWrapper.Execute(OrganizationRequest
request)
at
Microsoft.Xrm.Sdk.Client.OrganizationServiceContext.Execute(OrganizationRequest
request)
at
Microsoft.Xrm.Sdk.Linq.QueryProvider.RetrieveEntityCollection(OrganizationRequest
request, NavigationSource source)
at Microsoft.Xrm.Sdk.Linq.QueryProvider.Execute(QueryExpression qe,
Boolean throwIfSequenceIsEmpty, Boolean throwIfSequenceNotSingle,
Projection projection, NavigationSource source, List`1 linkLookups,
String& pagingCookie, Boolean& moreRecords)
at
Microsoft.Xrm.Sdk.Linq.QueryProvider.Execute[TElement](QueryExpression
qe, Boolean throwIfSequenceIsEmpty, Boolean throwIfSequenceNotSingle,
Projection projection, NavigationSource source, List`1 linkLookups)
at Microsoft.Xrm.Sdk.Linq.QueryProvider.Execute[TElement](Expression
expression)
at
Microsoft.Xrm.Sdk.Linq.QueryProvider.System.Linq.IQueryProvider.Execute[TResult](Expression
expression)
at System.Linq.Queryable.First[TSource](IQueryable`1 source)
I've seen similar questions here (probl is reffered to Id fields), but I
don't get it:
http://social.microsoft.com/Forums/en-US/7fbd2069-05a6-4b24-8bb1-9e104f713dc1/crm-linq-query
Microsoft Dynamics 2011 N:N LINQ query with where clause containing Guid
No comments:
Post a Comment