feat: sane date format
This commit is contained in:
parent
c12975926d
commit
4c710dcd20
4 changed files with 17 additions and 13 deletions
7
migrations/each_user/0014_birthday-format.sql
Normal file
7
migrations/each_user/0014_birthday-format.sql
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
update contacts
|
||||
set birthday = substr(birthday, 3, 2) || '-' || substr(birthday, 5, 2)
|
||||
where birthday GLOB '--[01][0-9][0-3][0-9]';
|
||||
|
||||
update contacts
|
||||
set birthday = substr(birthday, 1, 4) || '-' || substr(birthday, 5, 2) || '-' || substr(birthday, 7, 2)
|
||||
where birthday GLOB '[0-9][0-9][0-9][0-9][01][0-9][0-3][0-9]';
|
||||
Loading…
Add table
Add a link
Reference in a new issue