コード例 #1
0
		public OpenxmlFunction(VariableName variableName, SqlScriptableToken stringValue, IntegerLiteral flags, Optional<OpenxmlSchema> schema) {
			Debug.Assert(variableName != null);
			Debug.Assert(stringValue != null);
			Debug.Assert(schema != null);
			this.variableName = variableName;
			this.stringValue = stringValue;
			this.flags = (flags == null) ? 0 : (int)flags.Value;
			this.schema = schema;
		}
コード例 #2
0
		public ExecuteStatement(VariableName resultVariableName, Qualified<SchemaName, ProcedureName> procedureName, Optional<Sequence<ExecuteParameter>> parameters, OptionToken option) {
			Debug.Assert(procedureName != null);
			this.resultVariableName = resultVariableName;
			this.procedureName = procedureName;
			this.parameters = parameters.ToList();
			this.option = option;
			if (!procedureName.IsQualified && procedureName.Name.Value.StartsWith("sp_", StringComparison.OrdinalIgnoreCase)) {
				procedureName.LockOverride();
				int[] parameterPositions;
				if (objectNameParameters.TryGetValue(procedureName.Name.Value, out parameterPositions)) {
					foreach (int parameterPosition in parameterPositions.Where(p => this.parameters.Count > p)) {
						ExecuteParameter<Literal> objectNameParameter = (ExecuteParameter<Literal>)this.parameters[parameterPosition];
						if ((objectNameParameter != null) && (objectNameParameter.Value is StringLiteral)) {
							this.parameters[parameterPosition] = new ExecuteParameterObjectName(objectNameParameter.ParameterName, ((StringLiteral)objectNameParameter.Value), objectNameParameter.Output);
						}
					}
				}
			}
		}
コード例 #3
0
		public CreateXmlSchemaCollectionStatement(Qualified<SchemaName, XmlSchemaCollectionName> xmlSchemaCollectionName, VariableName variable): this(xmlSchemaCollectionName, ExpressionValue<VariableName>.CreateFrom(variable)) {}
コード例 #4
0
		public SetVariableMethodStatement(VariableName variableName, Sequence<NamedFunction> methods): base(variableName) {
			this.methods = methods.ToList();
		}
コード例 #5
0
		public UpdateExpressionItem(VariableName variableName, Expression expression): this(variableName, null, expression) {}
コード例 #6
0
		public UpdateExpressionItem(VariableName variableName, Qualified<SqlName, ColumnName> columnName, Expression expression): base(columnName, variableName) {
			this.expression = expression;
		}
コード例 #7
0
		public ColumnVariableItem(VariableName variableName, Expression expression) {
			Debug.Assert(expression != null);
			Debug.Assert(variableName != null);
			this.variableName = variableName;
			this.expression = expression;
		}
コード例 #8
0
		public CursorName(VariableName variableName): this(variableName.Value, false, false) {}
コード例 #9
0
		public DeclareVariableItem(VariableName variable, Qualified<SchemaName, TypeName> typeName, Expression initialization): base(variable) {
			Debug.Assert(typeName != null);
			this.typeName = typeName;
			this.initialization = initialization;
		}
コード例 #10
0
		public SourceVariableNodesRowset(VariableName variableName, NamedFunction functionCall, RowsetAlias rowsetAlias): base(functionCall, rowsetAlias) {
			this.variableName = variableName;
		}
コード例 #11
0
		public OpenxmlFunction(VariableName variableName, SqlScriptableToken stringValue, Optional<OpenxmlSchema> schema): this(variableName, stringValue, null, schema) {}
コード例 #12
0
		protected DeclareItem(VariableName variableName) {
			Debug.Assert(variableName != null);
			this.variableName = variableName;
		}
コード例 #13
0
		public DeclareTableStatement(VariableName variableName, Sequence<TableDefinition> tableDefinitions) {
			Debug.Assert(variableName != null);
			this.variableName = variableName;
			this.tableDefinitions = tableDefinitions.ToList();
		}
コード例 #14
0
		private UpdateMethodItem(VariableName variableName, Qualified<SqlName, ColumnName> columnName, Sequence<NamedFunction> methods): base(columnName, variableName) {
			this.methods = methods.ToList();
		}
コード例 #15
0
		public UpdateMethodItem(VariableName variableName, Sequence<NamedFunction> methods): this(variableName, null, methods) {}
コード例 #16
0
		public DeclareCursorItem(VariableName variable): base(variable) {}
コード例 #17
0
		public SourceTableVariableNodesRowset(VariableName tableName, ColumnName columnName, NamedFunction functionCall, RowsetAlias rowsetAlias): base(functionCall, rowsetAlias) {
			Debug.Assert(tableName != null);
			Debug.Assert(columnName != null);
			this.tableName = tableName;
			this.columnName = columnName;
		}
コード例 #18
0
		public DeclareVariableItem(VariableName variable, Qualified<SchemaName, TypeName> typeName): this(variable, typeName, null) {}
コード例 #19
0
		public SourceTableVariableRowset(VariableName tableName, RowsetAlias rowsetAlias): base(rowsetAlias) {
			Debug.Assert(tableName != null);
			this.tableName = tableName;
		}
コード例 #20
0
		protected UpdateItem(Qualified<SqlName, ColumnName> columnName, VariableName variableName) {
			Debug.Assert((columnName == null)^(variableName == null));
			this.columnName = columnName;
			this.variableName = variableName;
		}
コード例 #21
0
		public SetVariableCursorStatement(VariableName variableName, CursorDefinition definition): base(variableName) {
			if (definition.Global) {
				throw new ArgumentException("GLOBAL not allowed here");
			}
			this.definition = definition;
		}
コード例 #22
0
		public SetVariableExpressionStatement(VariableName variableName, Expression expression): base(variableName) {
			this.expression = expression;
		}
コード例 #23
0
		protected SetVariableStatement(VariableName variableName) {
			this.variableName = variableName;
			Debug.Assert(variableName != null);
		}