Skip to content

Created dim_classes.sql and dim_classes.yml. Updates stg_classes.sql.#34

Merged
RJO23 merged 2 commits into
mainfrom
create-dim-classes
Apr 13, 2026
Merged

Created dim_classes.sql and dim_classes.yml. Updates stg_classes.sql.#34
RJO23 merged 2 commits into
mainfrom
create-dim-classes

Conversation

@RJO23
Copy link
Copy Markdown
Collaborator

@RJO23 RJO23 commented Apr 10, 2026

finalized dim_classes with formatted columns and full accepted values testing. Also updated stg_classes.sql as this was previously missing 'capacity'.

…alues testing. Also updated stg_classes.sql as this was previously missing capacity.
@@ -11,6 +11,8 @@ staged as (

cast(category_id as integer) as category_id,
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Weren't we going to keep category ID as not an integer?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We did, but then it ended up clashing with a different model that someone else wrote and was throwing up an error. We decided to leave it as an integer for now.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes so in the stg_class_categgories, I believe @rosie-taylor you might have cast the parent and child ids as intergers and therfore the category id might have needed to be cast as and integer or inferred explicity.

Comment thread models/marts/dim_classes.sql
Comment thread models/marts/dim_classes.yml Outdated
- not_null
- accepted_values:
arguments:
values: ['Fitness', 'Combat', 'Wellness', 'Strength', 'Muay Thai', 'Boxing', 'Yoga', 'Pilates', 'Hiit', 'Mobility']
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The word "values" should be indented here to make sure the structure is valid, matching the class_name section above.

Comment thread models/marts/dim_classes.yml Outdated
- not_null
- accepted_values:
arguments:
values: ['Fitness', 'Combat', 'Wellness', 'Strength']
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"values" to be indented here too.

Comment thread models/marts/dim_classes.yml Outdated
- not_null
- accepted_values:
arguments:
values: ['Bow', 'Stratford', 'Canary Wharf', 'Hackney']
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"values" to be indented.

- accepted_values:
arguments:
quote: false
values: [15, 30, 45, 60, 75, 90]
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Values and quote should be indented under arguments.

Copy link
Copy Markdown
Collaborator

@EmilyYoung26 EmilyYoung26 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great!

@RJO23 RJO23 merged commit fde65d4 into main Apr 13, 2026
1 check passed
@RJO23 RJO23 deleted the create-dim-classes branch April 13, 2026 15:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants