1.输入 sudo apt-get install mysql-server

Ubuntu14.04下MySQL的安装

2.继续执行后,需要设定MySQL密码。

Ubuntu14.04下MySQL的安装

3.再次输入密码。

Ubuntu14.04下MySQL的安装

4.之后就安装成功了,输入mysql -u root -p进行登陆。

Ubuntu14.04下MySQL的安装

如果已经出现如上界面,那么mysql就可使用了

 

DROP TABLE IF EXISTS `t_org`;
CREATE TABLE `t_org` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`createTime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
`descr` varchar(255) DEFAULT NULL,
`iconCls` varchar(255) DEFAULT NULL,
`name` varchar(255) DEFAULT NULL,
`note` varchar(255) DEFAULT NULL,
`sn` varchar(255) DEFAULT NULL,
`tel` varchar(255) DEFAULT NULL,
`operator_id` int(11) DEFAULT NULL,
`parent_id` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `FK68F84994394CAB3` (`operator_id`),
KEY `FK68F8499A656A33D` (`parent_id`),
CONSTRAINT `FK68F84994394CAB3` FOREIGN KEY (`operator_id`) REFERENCES `t_admin` (`id`),
CONSTRAINT `FK68F8499A656A33D` FOREIGN KEY (`parent_id`) REFERENCES `t_org` (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8;

相关文章:

  • 2021-10-23
  • 2021-09-14
  • 2021-05-25
  • 2021-10-27
  • 2022-01-15
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-10-19
  • 2021-12-25
  • 2021-12-25
  • 2021-09-14
  • 2021-05-17
  • 2022-01-17
相关资源
相似解决方案