ObjectDatasource - Does it support multiple data tables?
I'm working with the ObjectDatasource and the application is getting more
and more chatty. Is there a way I could make the ObjectDatasource support
multiple DataTables that could be retrieved as one Dataset? I'm wondering
how others out there work with ObjectDatasource?
The only option I now see to get this fixed is to manually make the call to
the Web services, retrieve the Dataset and assign the datatable to the
controls (Or can I just assign it to the ObjectDataSource?)
RE: ObjectDatasource - Does it support multiple data tables?
Welcome to ASPNET newsgroup Felix,
As for the multiple data tables query with objectdatasource, do you mean
that the query used by your datasource will need to cover mutiple tables or
you just need to query multiple tables to local side and cache them so that
objectdatasource can use later? IMO, since objectdatasource control is
used to bind our databound server control with some custom data access
component classes, we can consider the customization on the data access
component class. In our custom data access component class, we can
encapsulate the internal mutiple data query or caching in the class and
call them through your exposed methods (select, update ....). e.g:
we can have class named OrderDAO which is used to manipulate Order datas
which will refer to other table like customer, order details..... Then,
we can define some private methods on the OrderDAO class such as an Init
method which is called by the class once(in constructor or in Select
method) when necessary, it will access database and read multiple data
tables and cache the results (datatables) in applciation cache for
So how you customize the Data Access component class is up to you, this is
the most flexible function objectdatasource has provided us.
Microsoft Online Support
Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
|All times are GMT. The time now is 01:58 AM.|
Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.