offdataai
Travel & Hospitality · data model template

Airline Revenue Analytics data model

Kimball warehouse for airline revenue management: transaction-grain bookings, a daily flight-leg periodic snapshot for load factor and RASM, and transaction-grain ancillary sales over conformed passenger/flight/route/fare-class/airport/aircraft dimensions. Passenger PII is classified and masked.

Airline commercial analytics covering ticketed bookings, daily flight-leg load-factor snapshots, and ancillary product sales over conformed passenger, flight, route, fare-class, airport, and aircraft dimensions — a Kimball star schema with SCD2 passenger history and regulated PII (passport number, frequent-flyer number) masked. It is a Kimball dimensional model: fact tables at a declared grain surrounded by conformed dimensions, ready for BI tools and a semantic layer.

KimballTravel & HospitalityPCI-DSSGDPR
11
tables
115
columns
15
relationships
7
PII columns

Opening the template creates a project with the ERD, platform-native DDL, a dbt project and documentation already generated (recommended platform: Snowflake). Edit it in plain English or on the canvas, then ship it to any supported warehouse.

Subject areas

bookingsflight_operationsancillary_revenueconformed_dimensions

Design decisions

  • Flight-leg snapshot separate from bookings

    Load factor and revenue-per-available-seat-mile are semi-additive leg-level metrics computed daily, independent of booking volume and timing.

  • Two date roles on the booking fact

    Booking date and travel date differ and drive different analyses (lead time, advance-purchase curves); both reference dim_date via a role-playing date key.

  • Ancillary sales as a separate fact

    Ancillary revenue (bags, seats, meals) has its own product dimension and grain and is increasingly material; isolating it keeps the booking fact clean and supports unbundling analysis.

  • Masking on passport and frequent-flyer numbers

    GDPR requires restricting access to government and loyalty identifiers; passport numbers are fully masked and FF numbers partially masked.

Tables in the Airline Revenue Analytics model

Every table with its grain, columns, types and keys. PK marks a primary key, BK a business key and PII a column classified as personal data, which gets a masking strategy by default.

Fact tables (3)

fct_booking

Grain: one row per ticketed booking segment (transaction)

Transaction-grain booking fact — one row per ticketed segment.

ColumnTypeKeys
booking_keybigintPK
date_keybigint
passenger_keybigint
flight_keybigint
route_keybigint
fare_class_keybigint
travel_date_keybigint
pnr_codevarchar
ticket_numbervarchar
base_faredecimal
taxes_amountdecimal
surcharge_amountdecimal
total_faredecimal
miles_earnedinteger
seat_countsmallint
booking_lead_time_daysinteger
channelvarchar
is_award_ticketboolean
is_cancelledboolean

fct_flight_leg_snapshot

Grain: one row per flight leg per departure day (periodic snapshot)

Daily flight-leg snapshot — load factor is semi-additive.

ColumnTypeKeys
date_keybigint
flight_keybigint
route_keybigint
aircraft_keybigint
origin_airport_keybigint
destination_airport_keybigint
seats_availablesmallint
seats_soldsmallint
passengers_boardedsmallint
no_show_countsmallint
load_factordecimal
leg_revenuedecimal
revenue_per_seat_miledecimal
on_time_flagboolean
departure_delay_minutesinteger

fct_ancillary_sale

Grain: one row per ancillary product sale (transaction)

Transaction-grain ancillary revenue (bags, seats, meals, lounge).

ColumnTypeKeys
ancillary_sale_keybigintPK
date_keybigint
passenger_keybigint
flight_keybigint
ancillary_type_keybigint
ancillary_order_idvarchar
quantitysmallint
unit_pricedecimal
gross_amountdecimal
discount_amountdecimal
net_amountdecimal
is_bundledboolean

Dimension tables (7)

dim_date

Grain: one row per calendar day

ColumnTypeKeys
date_keybigintPK
full_datedateBK
day_of_weekvarchar
month_numbersmallint
quartersmallint
yearsmallint
is_weekendboolean
is_holidayboolean
travel_seasonvarchar

dim_passenger

Grain: one row per passenger per SCD2 version

SCD type 2

ColumnTypeKeys
passenger_keybigintPK
passenger_idvarcharBK
first_namevarcharPII
last_namevarcharPII
emailvarcharPII
phonevarcharPII
date_of_birthdatePII
passport_numbervarcharPII
nationalityvarchar
country_of_residencevarchar
frequent_flyer_numbervarcharPII
loyalty_tiervarchar
lifetime_milesbigint
is_corporate_travelerboolean

dim_flight

Grain: one row per scheduled flight

ColumnTypeKeys
flight_keybigintPK
flight_idvarcharBK
flight_numbervarchar
carrier_codevarchar
carrier_namevarchar
is_codeshareboolean
operating_carriervarchar
service_typevarchar

dim_route

Grain: one row per origin-destination route

ColumnTypeKeys
route_keybigintPK
route_idvarcharBK
origin_airport_codevarchar
destination_airport_codevarchar
origin_regionvarchar
destination_regionvarchar
distance_milesinteger
is_internationalboolean
haul_typevarchar

dim_fare_class

Grain: one row per fare class

ColumnTypeKeys
fare_class_keybigintPK
fare_class_codevarcharBK
fare_class_namevarchar
cabinvarchar
booking_classvarchar
is_refundableboolean
is_changeableboolean
baggage_allowance_kgsmallint

dim_airport

Grain: one row per airport

ColumnTypeKeys
airport_keybigintPK
airport_codevarcharBK
airport_namevarchar
cityvarchar
countryvarchar
regionvarchar
timezonevarchar
is_hubboolean

dim_aircraft

Grain: one row per aircraft type

ColumnTypeKeys
aircraft_keybigintPK
aircraft_idvarcharBK
aircraft_typevarchar
manufacturervarchar
total_seatssmallint
economy_seatssmallint
business_seatssmallint
first_seatssmallint
range_milesinteger

Lookup tables (1)

dim_ancillary_type

Grain: one row per ancillary product type

ColumnTypeKeys
ancillary_type_keybigintPK
ancillary_codevarcharBK
ancillary_namevarchar
ancillary_categoryvarchar

Relationships

Each relationship is a foreign key on the first table referencing the second.

  • fct_booking.date_key → dim_date (many-to-one)
  • fct_booking.passenger_key → dim_passenger (many-to-one)
  • fct_booking.flight_key → dim_flight (many-to-one)
  • fct_booking.route_key → dim_route (many-to-one)
  • fct_booking.fare_class_key → dim_fare_class (many-to-one)
  • fct_flight_leg_snapshot.date_key → dim_date (many-to-one)
  • fct_flight_leg_snapshot.flight_key → dim_flight (many-to-one)
  • fct_flight_leg_snapshot.route_key → dim_route (many-to-one)
  • fct_flight_leg_snapshot.aircraft_key → dim_aircraft (many-to-one)
  • fct_flight_leg_snapshot.origin_airport_key → dim_airport (many-to-one)
  • fct_flight_leg_snapshot.destination_airport_key → dim_airport (many-to-one)
  • fct_ancillary_sale.date_key → dim_date (many-to-one)
  • fct_ancillary_sale.passenger_key → dim_passenger (many-to-one)
  • fct_ancillary_sale.flight_key → dim_flight (many-to-one)
  • fct_ancillary_sale.ancillary_type_key → dim_ancillary_type (many-to-one)

Related templates

All templates →
Start for $1

From requirements to AI-ready context, in one platform.

Describe your business in a conversation, start from a template or connect your own database. Your first model is ready in minutes.

Get startedBook a demo

Plans from $1/month · cancel any time