This is a migrated thread and some comments may be shown as answers.

ArgumentException: ResourceAssociationSet

1 Answer 35 Views
Web Services
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Praveen
Top achievements
Rank 1
Praveen asked on 09 Apr 2013, 12:19 PM
When trying to access a type which is self-referential, we get this error, but we don't know why or how to fix it.

"System.ArgumentException: The ends of a ResourceAssociationSet cannot both have the same ResourceType and ResourceProperty values. If this is a self-referencing association, the ResourceAssociationSet must be unidirectional with the ResourceProperty on one of the ends set to null."

Any ideas?

1 Answer, 1 is accepted

Sort by
0
Viktor Zhivkov
Telerik team
answered on 10 Apr 2013, 02:16 PM
Hi Praveen,

Thank you for your feedback.
There is indeed a bug in our way of handling self-references when both ends of the association have properties.
I have updated the OpenAccessMetadataProvider to handle properly this situation and you can find the new version of the file attached.
You can copy the fixed template over the original ones in
// for C# and Visual Studio 2012
C:\Program Files\Telerik\OpenAccess ORM\dsl2012\Extensibility\Dsw\Templates\CSharp\DataServices
// or for VB and Visual Studio 2012
C:\Program Files\Telerik\OpenAccess ORM\dsl2012\Extensibility\Dsw\Templates\VisualBasic\DataServices

If you are using Visual Studio 2010 please change dsl2012 to dsl2010.
If you are part of a team that actively uses Add OpenAccess Service wizard, please distribute the new code file to all team mates.

I am sorry for the inconvenience. I have also added 500 Telerik point for reporting a new bug in our product.

Regards,
Viktor Zhivkov
the Telerik team
Using Encrypted Connection Strings with Telerik OpenAccess ORM. Read our latest blog article >>
Tags
Web Services
Asked by
Praveen
Top achievements
Rank 1
Answers by
Viktor Zhivkov
Telerik team
Share this question
or