dim_date

-1 rows


Description

All dates from 1900-01-01 to 2099-12-31 with some precalculated values for common operations.

Columns

Column Type Size Nulls Auto Default Children Parents Comments
date_id int4 10 null
fct_checkin.checkin_date_id fct_checkin_checkin_date_id_fkey R
fct_checkin.checkout_date_id fct_checkin_checkout_date_id_fkey R
fct_class_appointment.created_date_id fct_class_appointment_created_date_id_fkey R
fct_class_appointment.end_date_id fct_class_appointment_end_date_id_fkey R
fct_class_appointment.start_date_id fct_class_appointment_start_date_id_fkey R
fct_class_event.end_date_id fct_class_event_end_date_id_fkey R
fct_class_event.event_date_id fct_class_event_event_date_id_fkey R
fct_class_event.start_date_id fct_class_event_start_date_id_fkey R
fct_contract.cancellation_date_id fct_contract_cancellation_date_id_fkey R
fct_contract.cancellation_receipt_date_id fct_contract_cancellation_receipt_date_id_fkey R
fct_contract.created_date_id fct_contract_created_date_id_fkey R
fct_contract.end_date_id fct_contract_end_date_id_fkey R
fct_contract.pre_cancellation_end_date_id fct_contract_pre_cancellation_end_date_id_fkey R
fct_contract.start_date_id fct_contract_start_date_id_fkey R
fct_contract.start_date_of_use_id fct_contract_start_date_of_use_id_fkey R
fct_contract_cancellation.cancellation_date_id fct_contract_cancellation_cancellation_date_id_fkey R
fct_contract_cancellation.cancellation_receipt_date_id fct_contract_cancellation_cancellation_receipt_date_id_fkey R
fct_contract_cancellation.contract_end_date_id fct_contract_cancellation_contract_end_date_id_fkey R
fct_contract_cancellation.pre_cancellation_end_date_id fct_contract_cancellation_pre_cancellation_end_date_id_fkey R
fct_idle_period.end_date_id fct_idle_period_end_date_id_fkey R
fct_idle_period.start_date_id fct_idle_period_start_date_id_fkey R
fct_payment_run.effective_collection_date_id fct_payment_run_effective_collection_date_id_fkey R
fct_revenue.accounting_date_id fct_revenue_accounting_date_id_fkey R
fct_trainer_class_appointments.end_date_id fct_trainer_class_appointments_end_date_id_fkey R
fct_trainer_class_appointments.start_date_id fct_trainer_class_appointments_start_date_id_fkey R

Primary key of this table. Built by formatting a date to yyyyMMdd.

date date 13 null
dim_customer.created_date dim_customer_created_date_fkey R
fct_contract_price_history.valid_from_date fct_contract_price_history_valid_from_date_fkey R
fct_contract_price_history.valid_to_date fct_contract_price_history_valid_to_date_fkey R
fct_contract_term_dates.end_date fct_contract_term_dates_end_date_fkey R
fct_contract_term_dates.start_date fct_contract_term_dates_start_date_fkey R
fct_customer_appointment.end_date fct_customer_appointment_end_date_fkey R
fct_customer_appointment.start_date fct_customer_appointment_start_date_fkey R
fct_lead_lifetime.lead_finish_date fct_lead_lifetime_lead_finish_date_fkey R
fct_lead_lifetime.lead_start_date fct_lead_lifetime_lead_start_date_fkey R
fct_revenue.service_period_start_date fct_revenue_service_period_start_date_fkey R
fct_trainer_appointment.end_date fct_trainer_appointment_end_date_fkey R
fct_trainer_appointment.start_date fct_trainer_appointment_start_date_fkey R

A numbered day of a month together with the numbered month and year. Primary key is derived from this.

year int4 10 null

The numbered year part of the date.

month int4 10 null

The numbered month part of the date.

day int4 10 null

The numbered day of month part of the date.

year_month int4 10 null

Year and month formatted to yyyyMM (eg 202201).

year_day int4 10 null

Year and day of month formatted to yyyydd (eg 202230).

month_day int4 10 null

Month and day of month formatted to MMdd (eg 131).

day_number_of_year int4 10 null

The numbered day of a year (1 to 365/366).

day_number_of_week int4 10 null

The numbered day of a week (0 to 6), starting at Sunday.

day_of_week varchar 256 null

DEPRECATED. Use weekday_name instead.
The english name of a day of a week (eg Monday).

month_name varchar 256 null

The linguistic name of the month (eg January).

weekday_name varchar 256 null

The linguistic name of the weekday (eg Monday).

is_start_of_month bool 1 null

True if the date represents the beginning of a month, otherwise False.

is_end_of_month bool 1 null

True if the date represents the end of a month, otherwise False.

last_updated timestamptz 35 null

System column. UTC Timestamp at which entry was calculated (lags behind source system).

Relationships