ApplySchema --batch-size
fails with --allow-zero-in-date
strategy flag
#13950
Labels
ApplySchema --batch-size
fails with --allow-zero-in-date
strategy flag
#13950
#13693 introduced a
--batch-size
flag, to be used withCREATE
statements only and withdirect
ddl strategy.When the ddl strategy includes
--allow-zero-in-date
,ApplySchema --batch-size <greater_than_1>
fails; this happens becauseTabletExecutor
attempts to inject query modifiers (specifically/*vt+ allowZeroInDate=true */
) into the SQL query. This is the relevant code:vitess/go/vt/schemamanager/tablet_executor.go
Lines 460 to 473 in 974579d
Problem is that with
--batch-size
the SQL can contain multiple queries.The bug was not caught because it only happens when
--allow-zero-in-date
is added, which wasn't tested in #13693's tests.The text was updated successfully, but these errors were encountered: