By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,424 Members | 1,375 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,424 IT Pros & Developers. It's quick & easy.

Linq

P: n/a
Hello,

I have the following Linq query:

PostPaper paper = (from p in database.Posts
where p.PostID == id
select new PostPaper {
Post =
p,
Tags = (from pt in database.PostsTags
join t in database.Tags on pt.TagID
equals t.TagID
where pt.PostID == id
orderby t.Name
select t.Name) as tb,
ViewTags = tb.ToArray()
}).SingleOrDefault();

The following is not working:
select t.Name) as tb,
ViewTags = tb.ToArray()

Basically, I need to define ViewTags as an array by converting the
list Tags.

Thanks,
Miguel
Sep 26 '08 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.