RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TADOCommand.CommandType Property

Specifies the type of command to execute.

Pascal
property CommandType: TCommandType;
C++
__property TCommandType CommandType;

Set CommandType to indicate the type of command that is contained in the CommandText property. The value in CommandType should agree with the value in CommandText. For instance, if CommandText is the name of a table, CommandType should be cmdTable or cmdTableDirect. 

The default value of CommandType is cmdUnknown. While CommandType may be left as cmdUnknown for all commands, setting CommandType to explicitly indicate the type of the command results in better performance. When CommandType is cmdUnknown, ADO must evaluate the command to determine its type, which slows the operation.

Note: The TCommandType constants cmdTable, cmdTableDirect, and cmdFile should not be used with commands executed from a TADOCommand component.
 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!