-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sweep: Create growth page #32
Conversation
Rollback Files For Sweep
This is an automated message generated by Sweep AI. |
Sweep: PR Reviewpages/growth.mdIntroduced a new markdown file for tracking and analyzing growth data, including SQL queries and visualization components. Sweep Found These Issues queries/events.sqlThe query now includes 'Growth' and 'Pump' events and adds a new computed column Sweep Found These Issues
baby-tracker/queries/events.sql Line 18 in cabe550
View Diff baby-tracker/queries/events.sql Lines 14 to 17 in cabe550
View Diff |
Here is the format of a typical growth entry. Note there is no space between the weight and kg "Growth","2024-05-16 15:18",,,"4.48kg","54.5cm","38cm", |
🚀 Resolved via 1fac84aHere were the changes I made: --- queries/events.sql
+++ queries/events.sql
---
+++
@@ -12,8 +12,16 @@
"End Condition",
notes,
case
- when "Type" = 'Growth' then cast(split_part("Start Condition", ' ', 1) as decimal)
+ when "Type" = 'Growth' then cast(split_part("Start Condition", 'kg', 1) as decimal)
else null
- end as weight_kg
+ end as weight_kg,
+ case
+ when "Type" = 'Growth' then cast(split_part(split_part("Start Condition", 'kg', 2), 'cm', 1) as decimal)
+ else null
+ end as length_cm,
+ case
+ when "Type" = 'Growth' then cast(split_part(split_part("Start Condition", 'cm', 2), 'cm', 1) as decimal)
+ else null
+ end as head_circumference_cm
from events
GROUP BY all
This is an automated message generated by Sweep AI. |
Description
This pull request introduces a new page dedicated to tracking and analyzing the growth of my newborn baby. It includes SQL queries for fetching growth events and displaying them in a line chart, showing the baby's weight over time.
Summary
growth.md
underpages
directory for growth tracking and analysis.growth_by_day
SQL query results.events.sql
query underqueries
directory to:select
statement for better readability.Growth
type events and calculate the weight in kilograms.Fixes #29.
💡 To get Sweep to edit this pull request, you can:
This is an automated message generated by Sweep AI.