Products table

The Products table in the FitStack - V2 schema has 23 columns, keyed by Id, with 2 foreign keys to Branding and Nutrition. 12 columns in MealLogIngredients, MealPlanDayItems, NutritionLogs, ScheduledItems and 8 more reference it.

Columns (23)

Columns of the Products table
ColumnTypeConstraintsDescription
Iduuidprimary key, not null
Slugcharacter varying(160)not null
DataSourcecharacter varying(50)not null
NutriScoreGradecharacter varying(10)not null
BrandingIduuidreferences Branding.Id
NutritionIduuidreferences Nutrition.Id
CurrentVersionintegernot null
DataQualityScorenumeric(5,2)
QualityTiertext
NutritionVerifiedbooleannot null
IngredientsVerifiedbooleannot null
BrandingVerifiedbooleannot null
BarcodeVerifiedbooleannot null
IsVerifiedbooleannot null
Countriestext[]not null
Countrycharacter varying(80)
Languagecharacter varying(8)
LastEditedByUserIdcharacter varying(450)
PendingAnnotatorReviewbooleannot null
CreatedAttimestamp with time zonenot null
ModifiedAttimestamp with time zone
IsDeletedbooleannot null
DeletedAttimestamp with time zone

Indexes (7)

  • (Slug) unique (IX_Products_Slug)
  • (BrandingId) unique (IX_Products_BrandingId)
  • (NutritionId) unique (IX_Products_NutritionId)
  • (Country) (IX_Products_Country)
  • (Language) (IX_Products_Language)
  • (LastEditedByUserId) (IX_Products_LastEditedByUserId)
  • (PendingAnnotatorReview) (IX_Products_PendingAnnotatorReview)

Relationships