Send feedback on this topic.
Teradata.Client.Provider
CommandType Property



Teradata.Client.Provider Namespace > TdCommand Class : CommandType Property
Gets or sets how the CommandText property is interpreted.
Syntax
'Declaration
 
Public Overrides NotOverridable Property CommandType As CommandType
'Usage
 
Dim instance As TdCommand
Dim value As CommandType
 
instance.CommandType = value
 
value = instance.CommandType
public override CommandType CommandType {get; set;}
public:
property CommandType CommandType {
   CommandType get() override;
   void set (    CommandType value) override;
}

Property Value

One of the System.Data.CommandType enumeration values. The default value is System.Data.CommandType.Text.
Exceptions
ExceptionDescription
Provider does not support the specified CommandType.
The CommandType is not one of the System.Data.CommandType enumeration members.
The CommandType property was changed while the command was in execute state or there is an outstanding associated TdDataReader.
The TdCommand is closed / disposed.
Remarks
The .NET Data Provider only supports System.Data.CommandType.StoredProcedure and System.Data.CommandType.Text values. The .NET Data Provider does not support System.Data.CommandType.TableDirect. When the CommandType property is set to StoredProcedure, the CommandText property can either be set to the name of the stored procedure or user defined CALL statement. When the CommandType property is set to System.Data.CommandType.StoredProcedure ,the .NET Data Provider will verify if the CommandText is a valid CALL statement. If the CommandText is not a valid CALL statement, the .NET Data Provider will assume the CommandText to be set with the stored procedure name and generate the stored procedure CALL Statement, that includes the stored procedure name and corresponding parameters.
Requirements

Target Platforms: Windows 8.1, Windows 10, Windows Server 2012 R2, Windows Server 2016, Windows Server 2019

See Also

Reference

TdCommand Class
TdCommand Members
TdCommand Class