예제 #1
0
        public void VisitInsertStatement(AstInsertStatement insertStatement)
        {
            Assert.IsType <AstInsertStatement>(this.expected);
            var expectedAst = (AstInsertStatement)this.expected;

            AssertVisit(expectedAst.Location, insertStatement.Location);
            AssertVisit(expectedAst.Values, insertStatement.Values);
        }
예제 #2
0
        public void ParseStatement_Insert()
        {
            var expectedAst = new AstInsertStatement()
            {
                Location = new AstLocation()
                {
                    Value = "soltysdb_kv"
                },
                Values = new AstValue(new[]
                {
                    new AstExpression()
                    {
                        Value = "aaa"
                    },
                    new AstExpression()
                    {
                        Value = "bbb"
                    }
                })
            };

            AstAssert.Statement(expectedAst, "INSERT INTO soltysdb_kv VALUES (aaa,bbb)");
        }