Skip to content

Commit 9f5a7ed

Browse files
authored
In the 'users' table, changed the 'is_admin' column from a 'bool' to a 'tinyint(1)' type, to be more explicit with MySQL Boolean representation. (#237)
Co-authored-by: GitHub Gen Changes <>
1 parent 21e11bd commit 9f5a7ed

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dirs/ecommerce/schema.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ CREATE TABLE `users` (
55
`email_address` varchar(255) COLLATE utf8mb4_0900_as_ci NOT NULL COMMENT 'Email address of the user, now stored case-insensitively',
66
`phone_number` varchar(15) NULL COMMENT 'Phone number of the user, now allowed to be NULL',
77
`country_code` char(3) NOT NULL DEFAULT '+1' COMMENT 'Country code for the phone number, defaults to US',
8-
`is_admin` bool NULL DEFAULT 0 COMMENT 'Flag indicating if the user is an admin, defaults to false',
8+
`is_admin` tinyint(1) NULL DEFAULT 0 COMMENT 'Flag indicating if the user is an admin, defaults to false',
99
`email_verified` bool NOT NULL DEFAULT 0 COMMENT 'Flag indicating if the user email address is verified, defaults to false',
1010
`created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT 'Timestamp of when the user was created',
1111
`updated_at` timestamp NULL ON UPDATE CURRENT_TIMESTAMP COMMENT 'Timestamp of the last update to the user record',

0 commit comments

Comments
 (0)