github-8867.slt 945 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. # Copyright Materialize, Inc. and contributors. All rights reserved.
  2. #
  3. # Use of this software is governed by the Business Source License
  4. # included in the LICENSE file at the root of this repository.
  5. #
  6. # As of the Change Date specified in that file, in accordance with
  7. # the Business Source License, use of this software will be governed
  8. # by the Apache License, Version 2.0.
  9. # Regression test for database-issues#8867.
  10. mode cockroach
  11. simple conn=mz_system,user=mz_system
  12. ALTER SYSTEM SET enable_refresh_every_mvs = true
  13. ----
  14. COMPLETE 0
  15. statement ok
  16. CREATE TABLE t (x int)
  17. statement ok
  18. INSERT INTO t VALUES (1)
  19. statement ok
  20. CREATE MATERIALIZED VIEW mv1
  21. WITH (REFRESH EVERY '10s' ALIGNED TO mz_now()::text::int8 + 3000)
  22. AS SELECT * FROM t
  23. statement ok
  24. CREATE MATERIALIZED VIEW mv2
  25. WITH (REFRESH EVERY '10 s' ALIGNED TO mz_now()::text::int8 + 3000)
  26. AS SELECT * FROM mv1
  27. query I
  28. SELECT * FROM mv1;
  29. ----
  30. 1
  31. query I
  32. SELECT * FROM mv2;
  33. ----
  34. 1