Use typed Dataset/DataRow on untyped Dataset (OR mapping)
Posted on 2008-10-07
I need to migrate a project from VB6 to c#
I have a problem with a library that works as a OR mapper
This library got their data in a recordset and than loops through the recordset as it would be objects
wegot table cars 1:n to tyres 1:n to deliverers
now there was a join to this 3 tables and 1 recordset with all neccessary information in it
the code can now browse fully object oriantated through this recordset like
for each car in datasource
for each tyre in car
for each deliverer in tyre
the classes maped the information from the recordset correct to the object.
now i like to use typed datasets as my classes. this works great if i have only one table as datasource. but if i have more than on table like in the example above i dont know how this can be done.
my apprach was to make a custom dataset an give acces to it with typed datarows. but i don't know how it can be done.
using third party OR mapper is no solution as the project doesn't allow it.
if typed datasets dont work it would be a complete custom solution with fully custom businessobject.
but i like the approach with typed datasets as they are very flexible and fast developed, but at the moment noas flexible as i need it.
hopefully you understand my problem. i add information if you need it.