博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

随笔分类 -  SQL

摘要:create table test (NAME varchar(20) not null, HOBBY varchar(20) not null); insert into test values('Adam','basketball'); insert into test values('Bill','basketball'); insert into test values('Bill','football'); insert into test values('Cyper',& 阅读全文

posted @ 2012-06-29 18:39 峰雪 阅读(194) 评论(0) 推荐(0)

摘要:表结构及内容CREATE TABLE IF NOT EXISTS `student` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(10) NOT NULL, `subject` varchar(10) NOT NULL, `score` int(11) NOT NULL, PRIMARY KEY (`id`)) INSERT INTO `student` (`id`, `name`, `subject`, `score`) VALUES(1, '小明', '英文', 80),(2, '小明 阅读全文

posted @ 2012-05-09 16:46 峰雪 阅读(908) 评论(0) 推荐(0)

摘要:一、表结构---- 表的结构 `client_status`--CREATE TABLE IF NOT EXISTS `client_status` ( `id` mediumint(8) unsigned NOT NULL AUTO_INCREMENT, `client_id` mediumint(8) unsigned NOT NULL, `addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (`id`),) ---- 转存表中的数据 `client_status`--INSERT INTO `cli... 阅读全文

posted @ 2012-03-26 17:06 峰雪 阅读(12987) 评论(2) 推荐(0)

摘要:语法:SHOW TABLE STATUS [{FROM | IN} db_name] [LIKE 'pattern' | WHERE expr]SHOW TABLE STATUS works likes SHOW TABLES, but provides a lot of information about each non-TEMPORARY table. You can also get this list using the mysqlshow --status db_name command. The LIKE clause, if present, indicates 阅读全文

posted @ 2012-03-15 15:09 峰雪 阅读(3443) 评论(0) 推荐(0)