generated from Real-Dev-Squad/website-template
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* initial checkin * count added * migration added * I don't know this * Update controllers/url.go Co-authored-by: Yash Raj <[email protected]> * test db updateds * Update controllers/url.go Co-authored-by: Yash Raj <[email protected]> * typo fix for IsDeleted * syntex fix * chore: fix naming deleted_at * chore: update error response * minor chnages * count is 50 now --------- Co-authored-by: Yash Raj <[email protected]> Co-authored-by: Prakash <[email protected]>
- Loading branch information
1 parent
a50e792
commit 6c48a8f
Showing
8 changed files
with
155 additions
and
100 deletions.
There are no files selected for viewing
9 changes: 9 additions & 0 deletions
9
cmd/bun/migrations/20240614194314_to_is_deleted_and_deleted_at.down.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,9 @@ | ||
BEGIN; | ||
--bun:split | ||
|
||
ALTER TABLE tiny_url DROP COLUMN is_deleted; | ||
--bun:split | ||
|
||
ALTER TABLE tiny_url DROP COLUMN deleted_at; | ||
|
||
COMMIT; |
11 changes: 11 additions & 0 deletions
11
cmd/bun/migrations/20240614194314_to_is_deleted_and_deleted_at.up.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 @@ | ||
BEGIN; | ||
|
||
--bun:split | ||
|
||
ALTER TABLE tiny_url ADD is_deleted bool null DEFAULT FALSE; | ||
|
||
--bun:split | ||
|
||
ALTER TABLE tiny_url ADD deleted_at timestamp null; | ||
|
||
COMMIT; |
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