UniCommand Constructor(String,UniConnection)
Initializes a new instance of the
UniCommand class with the text of the query and a %% object.
The following example creates a
UniCommand and sets some of its properties.
public void CreateCommand()
{
UniConnection myConnection = new UniConnection("Provider=SQL Server;Data Source=SERVER;Initial Catalog=Northwind;User ID=sa");
string mySelectQuery = "SELECT * FROM Test.Dept";
UniCommand myCommand = new UniCommand(mySelectQuery, myConnection);
myCommand.FetchSize = 100;
}
Public Sub CreateCommand()
Dim myConnection As New UniConnection _
("Provider=SQL Server;Data Source=SERVER;Initial Catalog=Northwind;User ID=sa")
Dim mySelectQuery As String = _
"SELECT * FROM Test.Dept"
Dim myCommand As New UniCommand(mySelectQuery, myConnection)
myCommand.FetchSize = 100
End Sub
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2