[ Team LiB ] Previous Section Next Section

19.1 Comments/Troubleshooting

All Command objects implement the IDbCommand interface from the System.Data namespace, and are thus quite similar. In all basic ADO.NET providers, the Command object encapsulates a SQL statement or stored procedure call.

Some Command classes for ADO.NET providers are shown in Table 19-1.

Table 19-1. Provider-specific Command classes

Class

Data source

System.Data.SqlClient.SqlCommand

SQL Server

System.Data.OleDb.OleDbCommand

An OLE DB provider

System.Data.Odbc.OdbcCommand

An ODBC driver

System.Data.OleDb.OracleCommand

Oracle

    [ Team LiB ] Previous Section Next Section