-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'dev' of https://github.com/Kernel360/F2-ENGLISH-CHALLEN…
- Loading branch information
Showing
8 changed files
with
41 additions
and
27 deletions.
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
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
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
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
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
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
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
15 changes: 15 additions & 0 deletions
15
user-api/src/main/resources/db/migration/V1.17.0__update.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,15 @@ | ||
UPDATE user | ||
SET nickname = CONCAT( | ||
CASE | ||
WHEN RAND() < 0.2 THEN '용감한 강아지 ' | ||
WHEN RAND() < 0.4 THEN '빠른 고양이 ' | ||
WHEN RAND() < 0.6 THEN '행복한 도마뱀 ' | ||
WHEN RAND() < 0.8 THEN '친절한 다람쥐 ' | ||
ELSE '빛나는 여우 ' | ||
END, | ||
LPAD(FLOOR(RAND() * 10000), 4, '0') | ||
) | ||
WHERE CHAR_LENGTH(nickname) < 4 || CHAR_LENGTH(nickname) > 12; | ||
|
||
ALTER TABLE `user` | ||
MODIFY COLUMN nickname VARCHAR(12) NOT NULL; |