in the beginning my database must be Microsoft access :(
and later migrate to sql server
so, i need LINQ and both of database
LINQ doesn't well done with Access, since they are different architecture. SQL is RelationShip Database while Access isn't
If as you said you'd better create each DAL for Each DataBase. I don't think you can handler both with the same EF. There will be a lot issue follow up.
amodius
Member
178 Points
384 Posts
can't query my dataset with linq
Feb 22, 2012 07:23 AM|LINK
hi there
as a sample project downlodable here: www.immobilzero.com\MvcApplication2.zip
i cannot write a linq query to my dataset
where is the problem'
if i start to write [datasetname] nothing happen :( seems the project can't see my dataset
thaicarrot
Contributor
5426 Points
1507 Posts
Re: can't query my dataset with linq
Feb 22, 2012 07:54 AM|LINK
I haven't take a look at your code but sound like you are abuse the usage of EF. Take aware how EF work. You are duplicate those.
Forgoes dataset because EF doesn't need dataset. As you said you increase more time to transfer data between DataSet and BLL it is wrong.
Weera
amodius
Member
178 Points
384 Posts
Re: can't query my dataset with linq
Feb 22, 2012 08:41 AM|LINK
in the beginning my database must be Microsoft access :(
and later migrate to sql server
so, i need LINQ and both of database
thaicarrot
Contributor
5426 Points
1507 Posts
Re: can't query my dataset with linq
Feb 22, 2012 10:04 AM|LINK
LINQ doesn't well done with Access, since they are different architecture. SQL is RelationShip Database while Access isn't
If as you said you'd better create each DAL for Each DataBase. I don't think you can handler both with the same EF. There will be a lot issue follow up.
Weera
Decker Dong ...
All-Star
118619 Points
18779 Posts
Re: can't query my dataset with linq
Feb 24, 2012 12:31 AM|LINK
Sorry I'm afraid that LINQ-TO-ACCESS isn't supported by Microsoft directly at present;But you can:
1)Use General Ado.net (OleDbDataAdapter.Fill into DataTable,and then use AsEnumerable() to bind with LINQ-TO-OBJECT)。
2)Download the 3-rd party control of LINQ-TO-ACCESS AND play with that(But Microsoft isn't responsible for that……,See:http://www.microsofttranslator.com/bv.aspx?from=zh-chs&to=en&a=http://www.cnblogs.com/ansiboy/archive/2011/03/27/1996848.html)