-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* update existing events with correct status * changelog master * r14 * simplify query * rm from changelog master * [ci skip] auto patch increment skip-checks: true Co-authored-by: ras-rm-bot <[email protected]>
- Loading branch information
1 parent
912dc7c
commit 9fe46d4
Showing
3 changed files
with
23 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
src/main/resources/database/changes/release-14/changelog.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
databaseChangeLog: | ||
|
||
- changeSet: | ||
id: 14.1 | ||
author: Jon Fox | ||
changes: | ||
- sqlFile: | ||
comment: update existing events with correct status | ||
path: update_existing_events_status.sql | ||
relativeToChangelogFile: true | ||
splitStatements: false |
11 changes: 11 additions & 0 deletions
11
src/main/resources/database/changes/release-14/update_existing_events_status.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
UPDATE collectionexercise.event AS e | ||
SET status = 'SCHEDULED' | ||
WHERE e.status = 'NOT_SET' | ||
AND e.timestamp >= now() | ||
AND e.timestamp IS NOT NULL; | ||
|
||
UPDATE collectionexercise.event AS e | ||
SET status = 'PROCESSED' | ||
WHERE e.status = 'NOT_SET' | ||
AND e.timestamp < now() | ||
AND e.timestamp IS NOT NULL; |