github-3955.td 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637
  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 https://github.com/MaterializeInc/database-issues/issues/3955
  10. > CREATE CLUSTER test (SIZE '4-4');
  11. > SET cluster = test;
  12. # In case the environment has other replicas
  13. > SET cluster_replica = r1
  14. > CREATE TABLE t (a int)
  15. > CREATE MATERIALIZED VIEW mv AS SELECT * FROM t
  16. # Note: We rely on testdrive's retry behavior here, as it takes some time for
  17. # the logging to catch up.
  18. > SELECT COUNT(*)
  19. FROM
  20. mz_materialized_views AS views,
  21. mz_introspection.mz_compute_exports AS compute_exports,
  22. mz_introspection.mz_compute_frontiers AS frontiers
  23. WHERE
  24. views.name = 'mv' AND
  25. views.id = compute_exports.export_id AND
  26. compute_exports.export_id = frontiers.export_id AND
  27. time > 0
  28. 1
  29. > DROP CLUSTER test CASCADE;