public void Invoke( WFromClause fromClause, List <WNamedTableReference> vertexTableList, List <WTableReferenceWithAlias> nonVertexTableList) { this.vertexTableList = vertexTableList; this.nonVertexTableList = nonVertexTableList; foreach (WTableReference tabRef in fromClause.TableReferences) { tabRef.Accept(this); } }
internal WFromClause GetFromClause() { if (TableReferences.Count == 0) { return(null); } var newFromClause = new WFromClause(); //generate tableReference in a reverse way, because the later tableReference may use the column of previous tableReference List <WTableReference> reversedTableReference = new List <WTableReference>(); for (var i = TableReferences.Count - 1; i >= 0; i--) { reversedTableReference.Add(TableReferences[i].ToTableReference()); } for (var i = reversedTableReference.Count - 1; i >= 0; i--) { newFromClause.TableReferences.Add(reversedTableReference[i]); } return(newFromClause); }
public void Invoke(WFromClause fromClause) { blocks = new List <AggregationBlock>() { new AggregationBlock() }; if (fromClause == null) { return; } foreach (WTableReference tabRef in fromClause.TableReferences) { tabRef.Accept(this); } for (int index = blocks.Count - 1; index >= 1; --index) { if (blocks[index].RootTableAlias == "dummy" && !blocks[index].TableInputDependency.Any()) { blocks.RemoveAt(index); } } }
public virtual void Visit(WFromClause node) { node.AcceptChildren(this); }
public WSelectQueryBlock() { FromClause = new WFromClause(); WhereClause = new WWhereClause(); }