Home Notices Documents Classes Download Others Rice
Classes  >  command  >  CommandText
command class : CommandText getter

Description

Gets a SQL statement.

Syntax

commandInstance.CommandText

Arguments

None

Return value

ClassDescription
stringA SQL statement.

Sample code

1:

connection cnn = new connection("Data Source=c:\somedirectory\somedatabase.sqlite3;Version=3;");

2:

cnn.Open();

3:

command cmm = new command("create table sometable (id int, name text);", cnn);

4:

string sqlStr = cmm.CommandText; // create table sometable (id int, name text);

Notes

None.

Links for reference

None.

Copyright © Rice All rights reserved.