• mysql 辅助表的加强


    从5.0到5.1,再到5.5,5.6,可以看到多了information_schema

    完了是多了performance_schema ,里面内容不断增加,

    这段时间学习oracle,还是世界上是最牛的数据库,发现里面的数据字典很牛,你想要的信息都能查到,很细,但是mysql就没有这么方便的途径了,比如说查进程,大家都知道show full processlist,但是5.0里面没有processlist这个表 ,你就没办法用sql 语句过滤进程,就比较头痛了。但是版本升级以后就不一样了。

    +---------------------------------------+
    | Tables_in_information_schema |
    +---------------------------------------+
    | CHARACTER_SETS |
    | COLLATIONS |
    | COLLATION_CHARACTER_SET_APPLICABILITY |
    | COLUMNS |
    | COLUMN_PRIVILEGES |
    | KEY_COLUMN_USAGE |
    | PROFILING |
    | ROUTINES |
    | SCHEMATA |
    | SCHEMA_PRIVILEGES |
    | STATISTICS |
    | TABLES |
    | TABLE_CONSTRAINTS |
    | TABLE_PRIVILEGES |
    | TRIGGERS |
    | USER_PRIVILEGES |
    | VIEWS |
    +---------------------------------------+

    5.1的 有28张表,多少11张

    mysql> show tables;
    +---------------------------------------+
    | Tables_in_information_schema |
    +---------------------------------------+
    | CHARACTER_SETS |
    | COLLATIONS |
    | COLLATION_CHARACTER_SET_APPLICABILITY |
    | COLUMNS |
    | COLUMN_PRIVILEGES |
    | ENGINES |
    | EVENTS |
    | FILES |
    | GLOBAL_STATUS |
    | GLOBAL_VARIABLES |
    | KEY_COLUMN_USAGE |
    | PARTITIONS |
    | PLUGINS |
    | PROCESSLIST |
    | PROFILING |
    | REFERENTIAL_CONSTRAINTS |
    | ROUTINES |
    | SCHEMATA |
    | SCHEMA_PRIVILEGES |
    | SESSION_STATUS |
    | SESSION_VARIABLES |
    | STATISTICS |
    | TABLES |
    | TABLE_CONSTRAINTS |
    | TABLE_PRIVILEGES |
    | TRIGGERS |
    | USER_PRIVILEGES |
    | VIEWS |
    +---------------------------------------+

    到了5.5, 猛增到40张了

    +---------------------------------------+
    | Tables_in_information_schema |
    +---------------------------------------+
    | CHARACTER_SETS |
    | COLLATIONS |
    | COLLATION_CHARACTER_SET_APPLICABILITY |
    | COLUMNS |
    | COLUMN_PRIVILEGES |
    | ENGINES |
    | EVENTS |
    | FILES |
    | GLOBAL_STATUS |
    | GLOBAL_VARIABLES |
    | KEY_COLUMN_USAGE |
    | PARAMETERS |
    | PARTITIONS |
    | PLUGINS |
    | PROCESSLIST |
    | PROFILING |
    | REFERENTIAL_CONSTRAINTS |
    | ROUTINES |
    | SCHEMATA |
    | SCHEMA_PRIVILEGES |
    | SESSION_STATUS |
    | SESSION_VARIABLES |
    | STATISTICS |
    | TABLES |
    | TABLESPACES |
    | TABLE_CONSTRAINTS |
    | TABLE_PRIVILEGES |
    | TRIGGERS |
    | USER_PRIVILEGES |
    | VIEWS |
    | INNODB_BUFFER_PAGE |
    | INNODB_TRX |
    | INNODB_BUFFER_POOL_STATS |
    | INNODB_LOCK_WAITS |
    | INNODB_CMPMEM |
    | INNODB_CMP |
    | INNODB_LOCKS |
    | INNODB_CMPMEM_RESET |
    | INNODB_CMP_RESET |
    | INNODB_BUFFER_PAGE_LRU |
    +---------------------------------------+

    还多了个新的performance_schema 

    | cond_instances |
    | events_waits_current |
    | events_waits_history |
    | events_waits_history_long |
    | events_waits_summary_by_instance |
    | events_waits_summary_by_thread_by_event_name |
    | events_waits_summary_global_by_event_name |
    | file_instances |
    | file_summary_by_event_name |
    | file_summary_by_instance |
    | mutex_instances |
    | performance_timers |
    | rwlock_instances |
    | setup_consumers |
    | setup_instruments |
    | setup_timers |
    | threads

    甲骨文似乎还抽出了MySQL的修订历史。修订历史将以前对无数行源代码进行的修改进行了分组,归纳到所谓的“变化集”中。一个变化集可以显示出某项具体功能发生的变化。它可以显示出修改者的身份、修改的时间和原因。

    可以看到在oracle的管理下,mysql 一直在前行,有人说什么被收购以后越来越闭源了,但是对于普通公司,用户来说,影响还是比较小的,我相信并没有会用到test框架和自己看源码的各个修订历史。

  • 相关阅读:
    深入理解Linux修改hostname
    逆水行舟,不进则退
    TNS-12541: TNS:no listener TNS-12560 TNS-00511: No listener
    Linux Tomcat 6.0安装配置实践总结
    Database 'xxx' cannot be upgraded because it is read-only or has read-only file Make the database or files writeable, and rerun recovery.
    Tomcat启动找不到JRE_HOME的解决方法
    ORACLE触发器判断是否更新了某个字段
    MS SQL错误:SQL Server failed with error code 0xc0000000 to spawn a thread to process a new login or connection. Check the SQL Server error log and the Windows event logs for information about possible related problems
    MS SQL 错误:The operation could not be performed because OLE DB provider "SQLNCLI10" for linked server "test" was unable to begin a distributed transaction.
    ORA-01078: failure in processing system parameters & LRM-00109: could not open parameter file
  • 原文地址:https://www.cnblogs.com/gqdw/p/2910129.html
Copyright © 2020-2023  润新知