Exemple #1
0
    private InsertStep GetInsertStep(InsertStatementGroup value)
    {
        var step = new InsertStep();

        step.Columns      = _statement.ColumnNames;
        step.Values       = value.Values;
        step.TableName    = _statement.Tables.First();
        step.DatabaseName = _statement.DatabaseName;
        return(step);
    }
Exemple #2
0
    private InsertStepRemote GetInsertStepRemote(InsertStatementGroup value)
    {
        var foo = new InsertStepRemote();

        foo.Columns      = _statement.ColumnNames;
        foo.Values       = value.Values;
        foo.Participant  = _statement.Participant;
        foo.DatabaseName = _statement.DatabaseName;
        foo.TableName    = _statement.Tables.First();
        return(foo);
    }
Exemple #3
0
    public override void EnterExpression_list(TSqlParser.Expression_listContext context)
    {
        base.EnterExpression_list(context);

        if (IsStatementInsert())
        {
            var statement = GetStatementAsInsert();
            var group     = new InsertStatementGroup();
            group.Values.AddRange(context.GetText().Split(",").ToList());
            statement.InsertValues.Add(group);
        }

        Debug.WriteLine(context.GetText());
    }