github-3501.td 924 B

1234567891011121314151617181920212223242526272829303132
  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. $ set-arg-default single-replica-cluster=quickstart
  10. $ kafka-create-topic topic=test
  11. $ kafka-ingest topic=test format=bytes
  12. jack,jill
  13. goofus,gallant
  14. > CREATE CONNECTION kafka_conn
  15. TO KAFKA (BROKER '${testdrive.kafka-addr}', SECURITY PROTOCOL PLAINTEXT);
  16. > CREATE SOURCE src
  17. IN CLUSTER ${arg.single-replica-cluster}
  18. FROM KAFKA CONNECTION kafka_conn
  19. (TOPIC 'testdrive-test-${testdrive.seed}')
  20. FORMAT CSV WITH 2 COLUMNS
  21. > CREATE MATERIALIZED VIEW v AS
  22. SELECT column1 || column2 AS c FROM src
  23. > SELECT * FROM v
  24. jackjill
  25. goofusgallant