Chinaunix

标题: 如何查询一个表的建立时间 [打印本页]

作者: wsliuhao    时间: 2007-05-21 18:50
标题: 如何查询一个表的建立时间
RT

上网搜了搜,找到了oracle的问题答案,不知道mysql是否支持这个查询,用过的朋友帮下,谢谢!
作者: tanyear    时间: 2007-05-22 07:51
show table status;
作者: wsliuhao    时间: 2007-05-22 09:05
谢谢,的确可以做到,还想问一下,如果我想精确定位到某个表,比如'tpd_b_load_q',该如何继续写?

用 where 过滤不出 。

[ 本帖最后由 wsliuhao 于 2007-5-22 09:06 编辑 ]
作者: yejr    时间: 2007-05-22 09:06
show table status like 'xx';
作者: wsliuhao    时间: 2007-05-22 10:12
能问一下,这属于什么用法?
不是sql语句呀,mysql自定义的用法?

[ 本帖最后由 wsliuhao 于 2007-5-22 10:14 编辑 ]
作者: lizheng83    时间: 2007-05-22 10:43
到mysql里查

mysql> help show
Name: 'SHOW'
Description:

SHOW has many forms that provide information about databases,
tables, columns, or status information about the server.
This section describes those following:

SHOW [FULL] COLUMNS FROM tbl_name [FROM db_name] [LIKE 'pattern']
SHOW CREATE DATABASE db_name
SHOW CREATE TABLE tbl_name
SHOW DATABASES [LIKE 'pattern']
SHOW [STORAGE] ENGINES
SHOW ERRORS [LIMIT [offset,] row_count]
SHOW GRANTS FOR user
SHOW INDEX FROM tbl_name [FROM db_name]
SHOW INNODB STATUS
SHOW [BDB] LOGS
SHOW PRIVILEGES
SHOW [FULL] PROCESSLIST
SHOW STATUS [LIKE 'pattern']
SHOW TABLE STATUS [FROM db_name] [LIKE 'pattern']
SHOW [OPEN] TABLES [FROM db_name] [LIKE 'pattern']
SHOW [GLOBAL | SESSION] VARIABLES [LIKE 'pattern']
SHOW WARNINGS [LIMIT [offset,] row_count]


The SHOW statement also has forms that provide information about
replication master and slave servers and are described in [Replication
SQL]:

SHOW BINLOG EVENTS
SHOW MASTER LOGS
SHOW MASTER STATUS
SHOW SLAVE HOSTS
SHOW SLAVE STATUS

If the syntax for a given SHOW statement includes a LIKE
'pattern' part, 'pattern' is a string that can contain the SQL '%'
and '_' wildcard characters.
The pattern is useful for restricting statement output to matching values.
作者: wsliuhao    时间: 2007-05-22 11:22
原来是这样,对mysql熟悉的不够,学习了,多谢!!




欢迎光临 Chinaunix (http://bbs.chinaunix.net/) Powered by Discuz! X3.2