Click or drag to resize

TDengine Class

Defined this Driver's mainly APIs
Inheritance Hierarchy
SystemObject
  TDengineDriverTDengine

Namespace:  TDengineDriver
Assembly:  TDengineDriver (in TDengineDriver.dll) Version: 1.0.6
Syntax
C#
public class TDengine

The TDengine type exposes the following members.

Constructors
  NameDescription
Public methodTDengine
Initializes a new instance of the TDengine class
Top
Methods
  NameDescription
Public methodStatic memberAffectRows
Get the number of rows affected by the executed SQL statement.
Public methodStatic memberCleanup
Clean up the running environment and call this API before the application exits.
Public methodStatic memberClose
Close the connection.
Public methodStatic memberConnect
Create a database connection and initialize the connection context. The parameters that need to be provided by user.
Public methodStatic memberConsume
Only synchronous mode, this function is used to get the result of subscription. If the interval between two calls to taos_consume is less than the polling cycle of the subscription, the API will block until the interval exceeds this cycle. If a new record arrives in the database, the API will return the latest record, otherwise it will return an empty result set with no records. If the return value is NULL, it indicates a system error.
Public methodEquals (Inherited from Object.)
Public methodStatic memberError
Public function,calling taos_errstr(IntPtr) inside.Get the reason why the last API call failed, and the return value is a string. Also see .
Public methodStatic memberErrorNo
Get the reason why the last API call failed, and the return value is the error code.
Public methodStatic memberFetchFields
Public methodStatic memberFetchLengths
Public methodStatic memberFetchRowAsync
Get the result set of asynchronous queries in batch, which can only be used with QueryAsync().FetchRowAsyncCallback
Public methodStatic memberFetchRows
Get the data in the query result set by rows.
Public methodStatic memberFieldCount
Get the number of columns in the query result set.
Protected methodFinalize (Inherited from Object.)
Public methodStatic memberFreeResult
Release the query result set and related resources. After the query is completed, be sure to call the API to release resources, otherwise it may lead to application memory leakage. However, it should also be noted that after releasing resources, if you call functions such as Consume(IntPtr) to obtain query results, it will lead the application to Crash.
Public methodGetHashCode (Inherited from Object.)
Public methodGetType (Inherited from Object.)
Public methodStatic memberInit
Initialize the running environment. If the application does not actively call the API, the API will be automatically called when the application call Connect(String, String, String, String, Int16), so the application generally does not need to call the API manually.
Public methodStatic memberLoadTableInfo
user application call this API to load all tables meta,this method call the native method LoadTableInfoDll. this method must be called before StmtSetSubTbname(IntPtr stmt, string name);
Protected methodMemberwiseClone (Inherited from Object.)
Public methodStatic memberOptions
Set client options, currently only time zone setting (_TSDB_OPTIONTIMEZONE)and encoding setting (_TSDB_OPTIONLOCALE) are supported. The time zone and encoding default to the current operating system settings.
Public methodStatic memberQuery
Public function. This API is used to execute SQL statements, which can be DQL, DML or DDL statements. Change the SQL command to UTF-8 to avoid error under Windows.
Public methodStatic memberQueryAsync
This API uses non-blocking call mode. Application can open multiple tables and manipulate(query or insert) opened table concurrently. So applications must ensure that opetations on the same table is completely serialized. Because that will cause some query and insert operations cannot be performed.
Public methodStatic memberResultPrecision
The precision of the timestamp field in the returned result set.
Public methodStatic memberSchemalessInsert
In addition to writing data using SQL or using the parameter binding API, writing can also be done using Schemaless, which eliminates the need to create a super table/data sub-table data structure in advance and writes data directly, while the TDengine system automatically creates and maintains the required table structure based on the written data content.
Public methodStatic memberStmtAddBatch
For INSERT only. add all current bound parameters to batch process. Must be called after each call to StmtBindParam/StmtBindSingleParamBatch, or all columns binds for one or more lines with StmtBindSingleParamBatch. User application can call any bind parameter API again to bind more data lines after calling to this API.
Public methodStatic memberStmtBindParam
For both INSERT and SELECT. bind a whole line data. The usage of structure TAOS_BIND is the same with MYSQL_BIND in MySQL.
Public methodStatic memberStmtBindParamBatch
for INSERT only bind one or multiple lines data. The parameter 'bind'
Public methodStatic memberStmtBindSingleParamBatch
bind a single column's data, INTERNAL used and for INSERT only.
Public methodStatic memberStmtClose
close STMT object and free resources.
Public methodStatic memberStmtErrorStr
get detail error message when got failure for any stmt API call. If not failure, the result returned in this API is unknown.
Public methodStatic memberStmtExecute
actually execute the INSERT/SELECT sql statement. User application can continue to bind new data after calling to this API.
Public methodStatic memberStmtInit
init a TAOS_STMT object for later use.
Public methodStatic memberStmtPrepare
prepare a sql statement,'sql' should be a valid INSERT/SELECT statement.
Public methodStatic memberStmtSetSubTbname
For INSERT only. Set a table name for binding table name as parameter. Only used for binding all tables in one stable, user application must call 'loadTableInfo' API to load all table meta before calling this API. If the table meta is not cached locally, it will return error.
Public methodStatic memberStmtSetTbname
For INSERT only. Used to bind table name as a parmeter for the input stmt object.
Public methodStatic memberStmtSetTbnameTags
For INSERT only. set a table name for binding table name as parameter and tag values for all tag parameters.
Public methodStatic memberStmtUseResult
For SELECT only,getting the query result. User application should free it with API 'FreeResult' at the end.
Public methodStatic memberSubscribe
This function is used for start subscription service.
Public methodToString (Inherited from Object.)
Public methodStatic memberUnsubscribe
Unsubscribe.
Top
Fields
  NameDescription
Public fieldStatic memberTSDB_CODE_SUCCESS
The success code return by major of this TDengineDriver's operators.
Top
See Also