CommandText
This property specifies the SQL statement or stored procedure to run against the Oracle database or the XML data used to store changes to the Oracle database.
Declaration
// C#
public override string CommandText {get; set;}Property Value
A string.
Implements
IDbCommand
Remarks
The default is an empty string.
When the CommandType property is set to StoredProcedure, the CommandText property is set to the name of the stored procedure. The command calls this stored procedure when an Execute method is called.
The effects of XmlCommandType values on CommandText are:
-
XmlCommandType=None.CommandTypeproperty determines the contents ofCommandText. -
XmlCommandType=Query.CommandTextmust be a SQL query. The SQL query should be a select statement.CommandTypeproperty is ignored. -
XmlCommandTypeproperty isInsert,Update, orDelete.CommandTextmust be an XML document.CommandTypeproperty is ignored.