Issue resolution
Recently came across an interesting issue from one of my colleagues, when he tried to create a rollup field, a message is telling that XAML formula definition for rollup field is invalid.
A little tracing and checking made me suspect that he did something wrong on creating the rollup field, and I was a bit surprised!
So what is the best way to resolve it?
By using MSSQL profiler I got that the relationship schema name for the parent and child entities was too long.
After researching a little bit, I found that the schema name and logical name for custom entities, attributes, relationships and for many-to-many relationship intersect tables have a maximum length of 50 characters.
Hope it helps!
Recently came across an interesting issue from one of my colleagues, when he tried to create a rollup field, a message is telling that XAML formula definition for rollup field is invalid.
A little tracing and checking made me suspect that he did something wrong on creating the rollup field, and I was a bit surprised!
So what is the best way to resolve it?
By using MSSQL profiler I got that the relationship schema name for the parent and child entities was too long.
After researching a little bit, I found that the schema name and logical name for custom entities, attributes, relationships and for many-to-many relationship intersect tables have a maximum length of 50 characters.
Hope it helps!
Hi Abed! I am having this problem and not sure exactly how to fix it... Could you give more details? Should I delete the field and create another one with the same schema name?
ReplyDeleteHello Elivis,
DeleteFirst make sure that your current field schema name is not longer than 50 characters, if yes then you need to delete the field and create a new one with schema name which is not longer than 50 characters :)
Hello Abed
Deleteso in case if no what i will do?
Hello Hani,
DeleteYou can use MSSQL profiler to trace the issue, or use MS Dynamics CRM tracer.
Use this tool to enable CRM tracer :
https://crmdiagtool2011.codeplex.com/
and this tool to easily read the trace file :
https://crmtracereader.codeplex.com/
This comment has been removed by a blog administrator.
ReplyDeleteHi Abed!
ReplyDeleteIm experiencing this in CRM 2016 Online. Do you why? I've tried the 'Copy' functionality of O365 of PROD to TEST.
Cheers,
Junyet
did you check the schema name and logical name for custom entities, attributes, relationships and for many-to-many ?
ReplyDeleteAlso set the scope of your business rules to "Entity" before export the solution :)
I had the same issue except in my case it was trying to insert New_entitynamexxxx that was 37 characters into the field RollupEntityBaseTableName which is nvarchar(32). Opening support case with Microsoft.
ReplyDeleteI experienced the same error ("XAML formula definition for rollup field is invalid") whilst amending an existing rollup field. It seems that this error often masks other problems, in my case it was a SQL timeout that was the true issue. The timeout was caused by the rollup modifying AsyncOperationBase, adding a new index sorted this:
ReplyDeleteCREATE NONCLUSTERED INDEX IX_RecurrencyCorrelationId
ON [dbo].[AsyncOperationBase] ([RecurrencePattern],[CorrelationId])
INCLUDE ([StatusCode],[AsyncOperationId],[StateCode])
Hats off to your presence of mind..I really enjoyed reading your blog. I really appreciate your information which you shared with us.
ReplyDeleteBest CRM System