PlanSubscriptions table

The PlanSubscriptions table in the FitStack - V2 schema has 22 columns, keyed by Id, with 2 foreign keys to Users. 1 column in ScheduledItems references it.

A user following a plan. Distinct from `PlanPurchases` (52), which is the money.

Columns (22)

Columns of the PlanSubscriptions table
ColumnTypeConstraintsDescription
Iduuidprimary key, not null
UserIdtextnot null, references Users.Id
SharedByUserIdtextreferences Users.Id
PlanTypeintegernot null
PlanIduuidnot nullPOLYMORPHIC — no FK.
Statusintegernot null`PlanSubscriptionStatus`.
SubscribedAttimestamp with time zonenot null
StartDatedatenot null
EndDatedate
SubscribedVersionintegernot null
AutoSyncToLatestbooleannot null
LastSyncedVersioninteger
CurrentWeekNumberinteger
CurrentDayNumberinteger
UserTimezonetext
NotificationsEnabledbooleannot null
GenerateAheadDaysintegernot null
IsSharedbooleannot null
CreatedAttimestamp with time zonenot null
ModifiedAttimestamp with time zone
IsDeletedbooleannot null
DeletedAttimestamp with time zone

Relationships