Hello every body I'm new in thos comunity; I'm currently use The Kingsway Soft SSIS Integration Toolkit for Microsoft Dynamics 365(CRM) and in my CRM Source Component(Editor) I would like to add this string
<fetch mapping='logical'>
<entity name='@[User::EntitiesName]'>
<all-attributes />
<filter type="and" >
<condition attribute="modifiedon" operator="ge" value="@[User::ModifiedOn]" />
</filter>
</entity>
</fetch>
The @[User::EntitiesName] variable is build at runtime; Also the value @[User::ModifiedOn] is build at runtime. I received the error
System.Exception: There was an error when retrieving the CRM metadata for the entity or FetchXML query provided.
KingswaySoft.IntegrationToolkit.DynamicsCrm.CrmServiceException:
CRM service call returned an error: An error has occurred when retrieving metadata for CRM entity '': CRM service call returned an error:
LogicalName is required when entity id is not specified(Error Code: -2147220989, Detail Message:
LogicalName is required when entity id is not specified) (SSIS Integration Toolkit for Microsoft Dynamics 365, v8.1.0.6275 - devenv, v14.0.23107.0)
KingswaySoft.IntegrationToolkit.DynamicsCrm.CrmServiceException: CRM service call returned an error:
LogicalName is required when entity id is not specified(Error Code: -2147220989, Detail Message: LogicalName is required when entity id is not specified)
System.ServiceModel.FaultException<KingswaySoft.DynamicsCrmServices.Soap2011.OrganizationService.OrganizationServiceFault>: LogicalName is required when entity id is not specified
(SSIS Integration Toolkit for Microsoft Dynamics 365, v8.1.0.6275 - devenv, v14.0.23107.0)
My Questions are
1) Is it a real error ? so I must type at compilation time, the value for @[User::EntitiesName] ?
2) Can I pass dynamically @[User::EntitiesName] at run time ?
plese se the Image
Best regards
*This post is locked for comments
Hi,
Did this work out for you, can you able to store the value into variable?
please send me the sample code. I am using Kingsway soft CRM source editor.
If you are getting this count in code, cant you loop through the list of entities and run the query and get the count for each entity and add to total?
Do you need sample code about how to run this fetch from C#?
<fetch version="1.0" mapping="logical" aggregate="true">
<entity name="account">
<attribute name="accountid" aggregate="count" alias="count" />
</entity>
</fetch>
this is working...but i have multiple entities to get record count, how to get for multiple entities
Hi,
As my requirment, i have to get record count of all entities in dynamic crm, so i am trying to loop and pass each entity name as user variable. Please help me with passing the entiy name as variable. OR if there is an other way of getting record count of all entities. Thank you
Hi
Please make sure when the values of the attributes are in double quotes and also make sure you use count aggregate as shown below
<fetch version="1.0" mapping="logical" aggregate="true" >
<entity name="incident" >
<attribute name="ticketnumber" alias="Total" aggregate="count" />
</entity>
</fetch>
Hi,
I have a similar requirement, i am trying get the count of records for all entities. Fetch XML does not work for unions, so i am trying to loop each entityname and get records.
For now i hardcoded the 1 entity name and passing that user variable, but not working. Please shed some light.
<fetch version="1.0" mapping="logical" aggregate="true">
<entity name=@[User::tablename]>
<attribute name=@[User::ColumnName] alias=@[User::tableAlias] aggregate="countcolumn" />
</entity>
</fetch>
Hi,
Try copying this code:
<fetch mapping='logical'> <entity name=@[User::EntitiesName]> <all-attributes /> <filter type="and" > <condition attribute="modifiedon" operator="ge" value=@[User::ModifiedOn] /> </filter> </entity> </fetch>
I removed the quotes from the parameters. I believe that they don't need quotes around them.
Apologies if you have done this already.
Hello Thomas ,Hello Daniel
I attached some scrennshot about
the problem is regarding Ole DB Destination that saves the data Mapping at design time
I attached the Screenshot images
GENERAL FLOW
DATA ABOUT EACH DINAMIC ITERATION
FETCH XML OF DATA FLOW KWS CRM SOURCE
OLE DB DESTINATION DINAMICS PARAMETER
Do you have any advice ?
thanks in advance
Possibly supply us with some screenshots of your SSIS like your CRM Source and your parameters. Just to get a more clear idea of whats going on.
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,253 Super User 2024 Season 2
Martin Dráb 230,188 Most Valuable Professional
nmaenpaa 101,156