Home > MCQs > Database Management > ADO.NET MCQs

ADO.NET MCQ

ADO.NET Quick Quiz

Question 1 of 10
  • You must create a stored procedure to retrieve the following details for the given customer:

    CustomerName, Address, PhoneNumber

    Which of the following is an ideal choice to get the result?

    Answer & Explanation

    Correct Answer: Return the result as three out parameters and command object

    Note: This Question is unanswered, help us to find answer for this one

  • Read the following statements: Dim dr As DataRow Dim objCustReader As Data.SqlClient.SqlDataReader Dim dtCustomers As DataTable With dtCustomers.Columns.Add(New DataColumn(

    Answer & Explanation

    Correct Answer: None of the above

    Note: This Question is unanswered, help us to find answer for this one

  • How can you make a data reader close connection automatically?

    Answer & Explanation

    Correct Answer: command.ExecuteReader(CommandBehavior.CloseConnection)

    Note: This Question is unanswered, help us to find answer for this one

  • ADO.NET is known for disconnected data extraction. Which of the following does not use the disconnected mechanism while extracting data from the database?

    Answer & Explanation

    Correct Answer: DataReader

    Note: This Question is unanswered, help us to find answer for this one

  • Which of the following implements IDataReader interface?

    Answer & Explanation

    Correct Answer: All of the above

    Note: This Question is unanswered, help us to find answer for this one

  • Which of the following options is ideally suited for managing database connections?

    Answer & Explanation

    Correct Answer: Close the connection as soon as database operation is done

    Note: This Question is unanswered, help us to find answer for this one

  • Which of the following is not associated with the command  object in ADO.NET 2.0?

    Answer & Explanation

    Correct Answer: cmd.ExecutePageReader()

    Note: This Question is unanswered, help us to find answer for this one

  • Which of the following is capable of returning multiple rows and multiple columns from the database?

    Answer & Explanation

    Correct Answer: All of the above 

    Note: This Question is unanswered, help us to find answer for this one

  • Which of the following options should you use to copy the edited rows from a dataset called ProductInfo into another dataset called Product Changes?

    Answer & Explanation

    Correct Answer: productChanges = productInfo.GetChanges()

    Note: This Question is unanswered, help us to find answer for this one

  • You use a Command object to retrieve employee names from the employee table in the database. Which of the following will be returned when this command is executed using the ExecuteReader method?

    Answer & Explanation

    Correct Answer: DataReader

    Note: This Question is unanswered, help us to find answer for this one

  • ADO.NET Quick Quiz

    battery

    Poor Results!

    You need a lot of improvement.

    Just don't give up!

    Correct Answers: 0/10

    Start Practicing with our MCQs given below.