TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Rich
NA
84
61.3k
IQueryable question
Jan 17 2012 7:42 PM
In regards to my code block below. Would the use of IQueryable<Sports_Leagues_Level> be better than the
var
keyword, and if so how would I implement it.
public void GetTeams()
{
var
Teams = from sll in db.Sports_Leagues_Level
join nba in db.nba_Team_Names on sll.ID equals nba.SLLid
join league in db.Sports_Leagues on sll.Leagues equals league.Id
select new
{
SllId = sll.ID,
Team = nba.Abreviated_Long,
League = league.LeaguesAbr
};
foreach (var item in Teams)
{
Console.WriteLine("{0} {1} {2}", item.SllId, item.League, item.Team);
}
}
Reply
Answers (
10
)
Returning Complete Sequence
IQueryable stored procedure