Thread safe statements (#406)

Previously, expressions and params were evaluated
during the planning phase. This change builds the query
plan without evaluating params and expressions
which are then evaluated only during the execution phase.
This commit is contained in:
Asdine El Hrychy
2021-06-04 10:56:23 +04:00
committed by GitHub
parent 7a98a2025f
commit 9918cd6f55
42 changed files with 946 additions and 795 deletions

View File

@@ -75,9 +75,9 @@ func TestParserUpdate(t *testing.T) {
require.NoError(t, err)
require.Len(t, q.Statements, 1)
stmt := q.Statements[0].(*statement.UpdateStmt)
stmt := q.Statements[0].(*statement.StreamStmt)
require.False(t, stmt.IsReadOnly())
require.EqualValues(t, test.expected, stmt.ToStream().Stream)
require.EqualValues(t, test.expected, q.Statements[0].(*statement.StreamStmt).Stream)
})
}
}