What is the difference between IEnumerable and IQueryable?
  • IEnumerable is an interface available in the System.Collection namespace.
  • Any collection that implements the IEnumerable makes it iterable.
  • The IEnumerable or the Generic IEnumerable must be used over in-memory objects.
  • IQueryable is an interface available in the System.Linq namespace and implements IEnumerable
  • The IQueryable interface provides the IQueryProvider, which is used to create LINQ providers used in data-centric operations such as LINQ-to-SQL etc.
  • By using the AsQueryable() method over a collection, we can convert it into an IQueryable collection.

C# Concepts •  Added 9 days ago

Join the Newsletter

Subscribe to get our latest content by email.
    We won't send you spam. Unsubscribe at any time.
    We use cookies to provide you with a great user experience, analyze traffic and serve targeted promotions.   Learn More   Accept