当前位置:网站首页>MySQL create table error 1067 - invalid default value for 'update_ time‘
MySQL create table error 1067 - invalid default value for 'update_ time‘
2022-06-11 14:12:00 【GoLang. fmt】
Error message :
1067 - Invalid default value for 'update_time'
terms of settlement :
timestamp You must give a default value , To create a successful .
CREATE TABLE `user` (
`id` int(11) unsigned NOT NULL AUTO_INCREMENT,
`name` varchar(20) NOT NULL DEFAULT '' COMMENT ' full name ',
`email` varchar(30) NOT NULL DEFAULT '' COMMENT ' mailbox ',
`is_admin` tinyint(1) NOT NULL DEFAULT '0' COMMENT ' Is it super administrator 1 Said is 0 It means not ',
`status` tinyint(1) NOT NULL DEFAULT '1' COMMENT ' state 1: It works 0: Invalid ',
`updated_time` timestamp NOT NULL DEFAULT '1970-01-01 10:00:00 ' COMMENT ' Last updated time ',
`created_time` timestamp NOT NULL DEFAULT '1970-01-01 11:00:00 ' COMMENT ' Insert time ',
PRIMARY KEY (`id`),
KEY `idx_email` (`email`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT=' User table ';
Successfully created 
边栏推荐
- sqlmap检测SQL-lab靶场
- MySQL advanced statement
- d区间到可空转换
- Unsealing easy QF PDA helps enterprises improve ERP management
- Extracting storage is the best memory method
- [signal processing] digital signal processing matlab design with GUI interface and report
- Xiaomi 9-wire brush ROM
- Leetcode 1963. 使字符串平衡的最小交换次数(学习)
- Variable parameter expression
- Kubernetes binary installation (v1.20.15) (VI) deploying worknode nodes
猜你喜欢

非常值得学习的调度开源库推荐

Is bone conduction earphone good for bone? Is bone conduction earphone harmful to the body?

Unsealing easy QF PDA helps enterprises improve ERP management

Recommandation de la Bibliothèque open source de programmation

How to quickly compress the size of video?
![[issue 268] accidentally submit the test code to the production environment. I will teach you six ways to solve it in seconds!](/img/e7/448ba3e38fe8c14301f4dfef7f0346.jpg)
[issue 268] accidentally submit the test code to the production environment. I will teach you six ways to solve it in seconds!

Precision alignment adjustment platform

强大的全文本搜索工具——AnyTXT Searcher

.NET C#基础(6):命名空间 - 有名字的作用域

Top 10 bone conduction earphones in the list, and five easy-to-use bone conduction earphones are recommended
随机推荐
Leetcode 1968. Construct an array whose elements are not equal to the average value of two adjacent elements (yes, finally solved)
cadence SPB17.4 - allegro - allegro_ free_ viewer
【clickhouse专栏】新建库角色用户初始化
Current situation and future development trend of global and Chinese metalworking fluid market from 2022 to 2028
三级分类展示
tampermonkey这玩意如何替换flash播放器为h5播放器?
Distributed file system and enterprise application -- elk enterprise log analysis system
六.开发记录之实验室服务器LXD部署
create_engine mysql connector加密方式报错
C# 设置窗体和系统的光标形状
vim二次替换
Extracting storage is the best memory method
Is the brokerage account given by qiniu business school safe? Do you charge for opening an account
tp6基于whoops的异常接管(漂亮的界面)
Precision alignment adjustment platform
Introduction to reverse learning - excellent assembly debugging tool OllyDbg
SQL: how to use the data of purchase order and sales order to calculate commodity cost by moving weighted average method
airtest自动化测试
Optimal dispatching (thermal power, wind and energy storage) (realized by Matlab)
Top 10 bone conduction earphones in the list, and five easy-to-use bone conduction earphones are recommended