To perform CRUD operations with LINQ to SQL, you need to define a ___________.

  • DataContext
  • SqlConnection
  • SqlCommand
  • DataAdapter
The correct option is 'DataContext'. In LINQ to SQL, the DataContext class is responsible for connecting to the database and managing the objects retrieved from it. It acts as a bridge between the database and the .NET objects, allowing you to perform Create, Read, Update, and Delete (CRUD) operations on the database using LINQ queries and methods.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *