Using Stored Procedures

Feb 15, 2008 at 5:20 PM
Still very new at using repository factory but I think I'm slowly getting the hang of it.

I used Service Factory with my solution so that I have WCFService.BusinessEntities and WCFService.DataAccess. I used Repository Factory to Create Business Entities From Database under BusinessEntities and then I Create Data Repository Classes From Business Entities under DataAccess to call the stored procedure I need.

I have 2 business entities A and B, with a sproc that returns fields that are either in A or B. Right now, I can map fields in A with the stored proc, and fields in B with the stored proc, but what happens is I have to call the generated functions separately ie. ARepository.spSearch() and then BRepository.spSearch(). Is this the proper way of doing this? Or is there a way to map one stored proc call to 2 business entities?