Integration Architect (Presenter)
This exercise will demonstrate how to split streams in ksqlDB.
Begin by looking at the orders_combined stream from the module 9 exercise, which has orders from both the US and the UK:
SELECT * FROM orders_combined EMIT CHANGES;
Click Run query and see that the results contain orders from both the US and the UK.
Create a new stream to contain only orders from the US:
CREATE STREAM us_orders AS
SELECT * FROM orders_combined
WHERE source = 'US';
Click Run query.
Create another new stream to contain only orders from the UK:
CREATE STREAM uk_orders AS
SELECT * FROM orders_combined
WHERE source = 'UK';
Click Run query.
We will only share developer content and updates, including notifications when new content is added. We will never send you sales emails. 🙂 By subscribing, you understand we will process your personal information in accordance with our Privacy Statement.