4using System.Threading.Tasks;
51 public override string[]
DefaultArgumentNames =>
new string[] {
"ConnectionString",
"UserName",
"Password" };
78 string ConnectionString =
Arguments[0].AssociatedObjectValue?.
ToString() ??
string.Empty;
79 OdbcConnection Connection;
85 Connection =
new OdbcConnection(ConnectionString);
92 ConnectionString = ConnectionString.Trim();
93 if (!ConnectionString.EndsWith(
";"))
94 ConnectionString +=
";";
96 ConnectionString +=
"User Id=" + UserName +
";Password=" + Password +
";";
97 Connection =
new OdbcConnection(ConnectionString);
101 await Connection.OpenAsync();
Creates a connection to an external ODBC database.
ConnectOdbc(ScriptNode ConnectionString, ScriptNode UserName, ScriptNode Password, int Start, int Length, Expression Expression)
Creates a connection to an external ODBC database.
override async Task< IElement > EvaluateAsync(IElement[] Arguments, Variables Variables)
Evaluates the function.
override string[] DefaultArgumentNames
Default Argument names
override bool IsAsynchronous
If the node (or its decendants) include asynchronous evaluation. Asynchronous nodes should be evaluat...
ConnectOdbc(ScriptNode ConnectionString, int Start, int Length, Expression Expression)
Creates a connection to an external ODBC database.
override IElement Evaluate(IElement[] Arguments, Variables Variables)
Evaluates the function.
override string FunctionName
Name of the function
Manages an ODBC SQL connection
Class managing a script expression.
Base class for multivariate funcions.
ScriptNode[] Arguments
Function arguments.
static readonly ArgumentType[] argumentTypes3Scalar
Three scalar parameters.
static readonly ArgumentType[] argumentTypes1Scalar
One scalar parameter.
Base class for all nodes in a parsed script tree.
int Length
Length of expression covered by node.
override string ToString()
Expression Expression
Expression of which the node is a part.
int Start
Start position in script expression.
Basic interface for all types of elements.