DB access issue

Topics: Customizing Orchard, General, Installing Orchard
Mar 13, 2013 at 4:58 AM
Edited Mar 13, 2013 at 5:09 AM
I am trying to get list of tag name using linq to entity. But i am getting assembly not loaded exception. My code is below. i have coded the below lines in item action of blogcontroller.

List<string> tagsList= new List<string>();
using (var scope = new TransactionScope(TransactionScopeOption.Suppress))
                using (BlogsEntities be = new BlogsEntities())
                    tagsList= (from taglist in obe.blog_Orchard_Tags_TagRecord select taglist.TagName).ToList();
Can you please let me know how to get the db values in blog controller?
Mar 13, 2013 at 5:23 AM
What assembly?
Mar 13, 2013 at 6:07 AM
The assembly which contains blog entities. i have referred my entity assembly in blogcontroller. eventhough i am getting error.
Mar 13, 2013 at 6:22 AM
Is this EF? Orchard does not support EF.
Mar 13, 2013 at 6:33 AM
Edited Mar 13, 2013 at 6:48 AM
Yes. It is entity framework. But i can access another entity name customerentities in orchard source.
Please let me know if you have any queries
Mar 13, 2013 at 6:49 AM
I don't understand: you seem to be asking us to debug your EF code, whereas Orchard doesn't even use EF.
Mar 13, 2013 at 6:55 AM
Orchard doesnt use EF. But i have added 2 entities. customer and blog entities. I can access customer entity but not able to access blog entity.
customer and blog entities are different DB.
Mar 13, 2013 at 7:25 AM
Shouldn't you be asking EF questions on an EF forum?