public void Execute(Dictionary <string, Table> tables, SqlIfElseStatement ifElseStatement) { var rawData = new RawData(_Command); var evaluator = new EvaluateBooleanExpression(rawData, _Database, _Command); var isTrue = evaluator.Evaluate(new List <RawTableRow>( ), ifElseStatement.Condition); if (isTrue && ifElseStatement.TrueStatement != null) { _Database.ExecuteStatement(_Command, ifElseStatement.TrueStatement); } else if (isTrue == false && ifElseStatement.FalseStatement != null) { _Database.ExecuteStatement(_Command, ifElseStatement.FalseStatement); } }
public override void Visit(SqlIfElseStatement codeObject) { }