Data Preparation

Learn More
Multi Table Schemas
Last updated

Last updated
{
"METADATA_SPEC_VERSION": "MULTI_TABLE_V1",
"tables": {
"guests": {
"primary_key": "guest_email",
"alternate_keys": ["credit_card_number"],
"columns": {
"guest_email": { "sdtype": "email", "pii": True },
"hotel_id": { "sdtype": "id", "regex_format": "HID_[0-9]{3}" },
"has_rewards": { "sdtype": "boolean" },
"room_type": { "sdtype": "categorical" },
"amenities_fee": { "sdtype": "numerical" },
"checkin_date": { "sdtype": "datetime", "datetime_format": "%d %b %Y"},
"checkout_date": { "sdtype": "datetime", "datetime_format": "%d %b %Y"},
"room_rate": { "sdtype": "numerical" },
"billing_address": { "sdtype": "address", "pii": True},
"credit_card_number": { "sdtype": "credit_card_number", "pii": True}
}
},
"hotels": {
"primary_key": "hotel_id",
"columns": {
"hotel_id": { "sdtype": "id", "regex_format": "HID_[0-9]{3}" },
"city": { "sdtype": "categorical" },
"state": { "sdtype": "categorical" },
"rating": { "sdtype": "numerical" },
"classification": { "sdtype": "categorical" }
}
}
},
"relationships": [{
"parent_table_name": "hotels",
"parent_primary_key": "hotel_id",
"child_table_name": "guests",
"child_foreign_key": "hotel_id"
}]
}