Chapter 20. The Parameter Class
The Parameter
class
works with the Command
class to execute
parameterized commands or call stored procedures. Every
Command
object exposes a
Parameters
collection. In this collection,
there is one Parameter
object for every input and
output parameter, and an additional Parameter
object to represent a return value, if required.
The Parameter
object can also define a mapping
between parameters and columns in a DataSet
. This
allows a column value to be submitted (copied from the
DataSet
into an input parameter) and refreshed
(copied from an output parameter or return value into the
DataSet
) automatically when using the
Update( )
method of the
DataAdapter
.
Get ADO.NET in a Nutshell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.