Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8800183
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T00:31:12+00:00 2026-06-14T00:31:12+00:00

In my database context class I have: Imports System.Data.Entity Public Class MusicStoreEntities Inherits DbContext

  • 0

In my database context class I have:

Imports System.Data.Entity
Public Class MusicStoreEntities
    Inherits DbContext
    Public Property Albums As DbSet(Of Album)
    Public Property Descriptions As DbSet(Of Description)
End Class

Then, I have those two models for Album and Description

Public Class Album
    Public Property AlbumId As Integer
End Class

Public Class Description
    Public Property DescriptionId As Integer
    Public Property AlbumId As Integer
End Class

From an Action of a Controller I can get a single Description for an Album using Linq as the following:

Dim album_description As Description = db.Descriptions.Single(Function(g) g.AlbumId = id)

However, how can I get a list of Descriptions for an Album?

Dim album_descriptions As List(Of Description) = db.Descriptions.**???**(Function(g) g.AlbumId = id)
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T00:31:13+00:00Added an answer on June 14, 2026 at 12:31 am

    Use the .Where() method, documented here.

    db.Descriptions.Where(Function(g) g.AlbumId = id).ToList()
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm importing data between two different database(which have not the same context). So I've
Context In our application, we snapshot data from a database using a query that
for example I'm trying to get the data from database like: using (ExplorerDataContext context
I have an existing SQL Server database, where I store data from large specific
Trying to connect to the database ; I have a problem context = null
In MySQL database context, what is the difference among these 3 terms: stored procedure
i get this error Cannot open database DataLayer.Context.MedicallexiconContext requested by the login. The login
In context of Oracle 9i database, usually for a view to be created an
Context I'm using redis. The database is < 100 MB. However, I want to
Context This is purely for education purposes. I want to write a primitive database.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.