github-5474.slt 770 B

12345678910111213141516171819202122232425262728293031
  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 issues corrected by https://github.com/MaterializeInc/database-issues/issues/5474.
  10. # Regression test for database-issues#5474.
  11. statement ok
  12. CREATE TABLE t0(c0 VARCHAR(203) );
  13. statement ok
  14. INSERT INTO t0 VALUES ('0'), ('1');
  15. statement ok
  16. CREATE TABLE t2(c0 CHAR(206) );
  17. query TT
  18. SELECT
  19. *
  20. FROM
  21. t0 LEFT OUTER JOIN t2 ON t2.c0 = CAST(0 AS VARCHAR)
  22. ----
  23. 0
  24. NULL
  25. 1
  26. NULL