AdoDotNetConnectionSupport.GetCommand Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Constructs a DbCommand object from the given command string.
protected:
virtual System::Data::Common::DbCommand ^ GetCommand(System::String ^ command, Microsoft::VisualStudio::Data::Services::SupportEntities::DataCommandType commandType, cli::array <Microsoft::VisualStudio::Data::Services::SupportEntities::IVsDataParameter ^> ^ parameters, int commandTimeout);
protected virtual System.Data.Common.DbCommand GetCommand (string command, Microsoft.VisualStudio.Data.Services.SupportEntities.DataCommandType commandType, Microsoft.VisualStudio.Data.Services.SupportEntities.IVsDataParameter[] parameters, int commandTimeout);
abstract member GetCommand : string * Microsoft.VisualStudio.Data.Services.SupportEntities.DataCommandType * Microsoft.VisualStudio.Data.Services.SupportEntities.IVsDataParameter[] * int -> System.Data.Common.DbCommand
override this.GetCommand : string * Microsoft.VisualStudio.Data.Services.SupportEntities.DataCommandType * Microsoft.VisualStudio.Data.Services.SupportEntities.IVsDataParameter[] * int -> System.Data.Common.DbCommand
Protected Overridable Function GetCommand (command As String, commandType As DataCommandType, parameters As IVsDataParameter(), commandTimeout As Integer) As DbCommand
Parameters
- command
- String
Command to execute that is specific to the data source.
- commandType
- DataCommandType
Type of the indicated command, specifying how to interpret the contents of the command
parameter.
- parameters
- IVsDataParameter[]
Array of IVsDataParameter objects for the specified command type.
- commandTimeout
- Int32
Length of time, in seconds, to block the client before canceling the schema derivation and returning to the caller. A value of zero indicates infinite time-out; a value of -1 indicates a provider default.
Returns
A DbCommand object instance.