Conversation
|
The default an be inferred from the first |
|
@nilmerg not sure if I understand this right, but the Edit: Or do you mean to select the timezone value from the first |
5da9a2d to
7830d9e
Compare
Exactly. |
51a9f85 to
1cc5e6d
Compare
1cc5e6d to
d974095
Compare
julianbrost
left a comment
There was a problem hiding this comment.
This PR is fine and can be merged any time the corresponding Notifications Web PR is ready. Though it probably shouldn't merged earlier as the added column is required without a default, hence without the corresponding change in Notifications Web, older version can't insert new rows anymore.
Thus, I've converted the PR to a draft for the moment (so there's a hint that it maybe shouldn't be merged immediately despite this approval) with a corresponding note in the PR description.
The value must not be null, so we have to set a default when upgrading the schema. For that we look for the first `timeperiod_entry` and use it's `timezone` column. If no entry exists, the fallback is **'UTC'**.
d974095 to
8cf4067
Compare
This gives a single file that can be applied during the upgrade more easily, having it in individual files was mostly to avoid merge conflicts during development. The combined files were created with the following command: cat 0.2.0-external-uuid.sql <(echo) 0.2.0-source-rules.sql <(echo) 0.2.0-schedule-timezone.sql <(echo) 0.2.0-source-username.sql > 0.2.0.sql The order of files matches the order in which the PRs that added them were merged (though the order shouldn't really matter as there are no dependencies between the individual files): - #216 - #324 - #344 - #338
This gives a single file that can be applied during the upgrade more easily, having it in individual files was mostly to avoid merge conflicts during development. The combined files were created with the following command: cat 0.2.0-external-uuid.sql <(echo) 0.2.0-source-rules.sql <(echo) 0.2.0-schedule-timezone.sql <(echo) 0.2.0-source-username.sql > 0.2.0.sql The order of files matches the order in which the PRs that added them were merged (though the order shouldn't really matter as there are no dependencies between the individual files): - #216 - #324 - #344 - #338
Add a column to store the timezone the schedule is created for.
Draft until the following PR is merged: