Web Shipping Audit
Part of the Connected Data section of Coddy's PostgreSQL journey. Lesson 20 of 25.
Challenge
MediumReturn id, destination and item_count for web-channel orders with at least two items. destination is the nested shipping city or Unknown if missing. item_count must be an integer. Order by id.
The input tables are shown in the test panel. Each run starts from fresh data. Return the named columns in the stated order; do not hard-code the displayed rows.
Try it yourself
-- Write your SQL here.
All lessons in Connected Data
1Connect Tables
Match Rows with JOINKeep Rows with LEFT JOINCount After a JoinFind Missing MatchesCustomer Coverage4Work with JSONB
Read JSONB FieldsNavigate Nested JSONConvert JSON NumbersMatch JSONB StructureWeb Shipping AuditPractice on your own: PostgreSQL playground