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

Separate model and context

1 Answer 40 Views
Data Access Free Edition
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Sandr
Top achievements
Rank 1
Sandr asked on 30 Jan 2015, 04:05 PM
Hello,

I separated my model and my context, int two differents assemblies, using this method :
http://docs.telerik.com/data-access/developers-guide/data-access-domain-model/managing-the-openaccesscontext/data-access-tasks-create-data-access-context

Callers methods stored procedures are no longer generated, perhaps because my context is in a different assembly?
Have you ever tried this? If so, have you experienced this problem?

Thank you in advance

1 Answer, 1 is accepted

Sort by
0
Kaloyan Nikolov
Telerik team
answered on 04 Feb 2015, 12:58 PM
Hello,

The remote Data Access Domain context is not designed to generate the Domain Methods and the behavior you describe is expedited. It is designed to be a light weight context that you can use in any assembly but use the classes and metadata defined in your model assembly.

If you want to decouple the context from the other code I would suggest you to manually define an interface then to inherit it in the context generated by Data Access and use the interface in the rest of the code. For the entity classes you should reference the main model assembly anyway. You can also use the interface generated by Data Access. 

Should you have any further questions do not hesitate to get back to us. 

Regards,
Kaloyan Nikolov
Telerik
 
OpenAccess ORM is now Telerik Data Access. For more information on the new names, please, check out the Telerik Product Map.
 
Tags
Data Access Free Edition
Asked by
Sandr
Top achievements
Rank 1
Answers by
Kaloyan Nikolov
Telerik team
Share this question
or