Which database is the ADO.NET SqlConnection object designed for?
-
Access
-
Microsoft SQL Server
-
MySQL
-
Oracle
-
None of the above.
To answer this question, the user needs to have knowledge about ADO.NET and SqlConnection object.
The SqlConnection object in ADO.NET is designed for connecting and interacting with Microsoft SQL Server databases.
Therefore, the correct answer is:
The Answer is: B. Microsoft SQL Server
SqlConnection (in System.Data.SqlClient) is the ADO.NET provider-specific class built exclusively to connect to Microsoft SQL Server, using SQL Server's native TDS protocol for better performance than generic OLE DB/ODBC access. Connecting to Access, MySQL, or Oracle requires different provider classes (OleDbConnection/MySqlConnection/OracleConnection respectively) because each database has its own wire protocol that SqlConnection doesn't implement. So "Microsoft SQL Server" is correct, and "none of the above" is wrong since SQL Server is explicitly the intended target.