Interface IQueryExecutor
Interface which must be implemented to execute parsed sql queries. If this interface is implemented correctly, the library is designed to work in any way.
Namespace: SqlDotNet.CLRInterface
Assembly: SqlDotNet.dll
Syntax
public interface IQueryExecutor
Methods
| Improve this Doc View SourceCallFunction(String, IList<QueryParameter>)
Call an sql function or aggregation function
Declaration
Tuple<object, DataType> CallFunction(string name, IList<QueryParameter> parameter)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | Name of the function |
System.Collections.Generic.IList<QueryParameter> | parameter | List of parameter |
Returns
Type | Description |
---|---|
System.Tuple<System.Object, DataType> | Return value as object with specific type |
GetTableSchema(String, String)
Get the table definitions
Declaration
TableDefinition GetTableSchema(string owner, string table)
Parameters
Type | Name | Description |
---|---|---|
System.String | owner | Table owner (user, db, ...) |
System.String | table | Table name |
Returns
Type | Description |
---|---|
TableDefinition |
Insert(String, IList<String>, IList<QueryParameter>)
Insert data into some table
Declaration
int Insert(string tableName, IList<string> columns, IList<QueryParameter> parameter)
Parameters
Type | Name | Description |
---|---|---|
System.String | tableName | Name of the table |
System.Collections.Generic.IList<System.String> | columns | List of columns. If no columns are called, used an ordered object id or match by types |
System.Collections.Generic.IList<QueryParameter> | parameter | List of parameter |
Returns
Type | Description |
---|---|
System.Int32 | Amount of affected rows |
Select(String, Boolean, Boolean, IList<ColumnDefinition>, FilterCursorCCNode, Scope)
Declaration
IList<QueryResultRow> Select(string tableName, bool isScalar, bool distinctValues, IList<ColumnDefinition> columns, FilterCursorCCNode filter, Scope parameter)
Parameters
Type | Name | Description |
---|---|---|
System.String | tableName | |
System.Boolean | isScalar | |
System.Boolean | distinctValues | |
System.Collections.Generic.IList<ColumnDefinition> | columns | |
FilterCursorCCNode | filter | |
Scope | parameter |
Returns
Type | Description |
---|---|
System.Collections.Generic.IList<QueryResultRow> |