当前位置: 首页 > news >正文

MySQL Show命令集

MySQL SHOW 命令

1、mysql shell 查看帮助show

(root@localhost) [(none)]> \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 {BINARY | MASTER} LOGS
SHOW BINLOG EVENTS [IN 'log_name'] [FROM pos] [LIMIT [offset,] row_count]
SHOW CHARACTER SET [like_or_where]
SHOW COLLATION [like_or_where]
SHOW [FULL] COLUMNS FROM tbl_name [FROM db_name] [like_or_where]
SHOW CREATE DATABASE db_name
SHOW CREATE EVENT event_name
SHOW CREATE FUNCTION func_name
SHOW CREATE PROCEDURE proc_name
SHOW CREATE TABLE tbl_name
SHOW CREATE TRIGGER trigger_name
SHOW CREATE VIEW view_name
SHOW DATABASES [like_or_where]
SHOW ENGINE engine_name {STATUS | MUTEX}
SHOW [STORAGE] ENGINES
SHOW ERRORS [LIMIT [offset,] row_count]
SHOW EVENTS
SHOW FUNCTION CODE func_name
SHOW FUNCTION STATUS [like_or_where]
SHOW GRANTS FOR user
SHOW INDEX FROM tbl_name [FROM db_name]
SHOW MASTER STATUS
SHOW OPEN TABLES [FROM db_name] [like_or_where]
SHOW PLUGINS
SHOW PROCEDURE CODE proc_name
SHOW PROCEDURE STATUS [like_or_where]
SHOW PRIVILEGES
SHOW [FULL] PROCESSLIST
SHOW PROFILE [types] [FOR QUERY n] [OFFSET n] [LIMIT n]
SHOW PROFILES
SHOW RELAYLOG EVENTS [IN 'log_name'] [FROM pos] [LIMIT [offset,] row_count]
SHOW {REPLICAS | SLAVE HOSTS}
SHOW {REPLICA | SLAVE} STATUS [FOR CHANNEL channel]
SHOW [GLOBAL | SESSION] STATUS [like_or_where]
SHOW TABLE STATUS [FROM db_name] [like_or_where]
SHOW [FULL] TABLES [FROM db_name] [like_or_where]
SHOW TRIGGERS [FROM db_name] [like_or_where]
SHOW [GLOBAL | SESSION] VARIABLES [like_or_where]
SHOW WARNINGS [LIMIT [offset,] row_count]like_or_where: {LIKE 'pattern'| WHERE expr
}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.Several SHOW statements also accept a WHERE clause that provides more
flexibility in specifying which rows to display. See
https://dev.mysql.com/doc/refman/8.0/en/extended-show.html.In SHOW statement results, user names and host names are quoted using
backticks (`).URL: https://dev.mysql.com/doc/refman/8.0/en/show.html

2、查看存储引擎的状态


(root@localhost) [(none)]> SHOW ENGINE INNODB STATUS \G;
*************************** 1. row ***************************Type: InnoDBName:Status:
=====================================2024-06-08 11:54:25 139900802344704 INNODB MONITOR OUTPUT
=====================================Per second averages calculated from the last 14 seconds
-----------------BACKGROUND THREAD
-----------------srv_master_thread loops: 6 srv_active, 0 srv_shutdown, 435284 srv_idlesrv_master_thread log flush and writes: 0
----------SEMAPHORES
----------OS WAIT ARRAY INFO: reservation count 89
OS WAIT ARRAY INFO: signal count 87
RW-shared spins 0, rounds 0, OS waits 0
RW-excl spins 0, rounds 0, OS waits 0
RW-sx spins 0, rounds 0, OS waits 0Spin rounds per wait: 0.00 RW-shared, 0.00 RW-excl, 0.00 RW-sx
------------TRANSACTIONS
------------Trx id counter 48991
Purge done for trx's n:o < 48986 undo n:o < 0 state: running but idle
History list length 0
LIST OF TRANSACTIONS FOR EACH SESSION:
---TRANSACTION 421376845869056, not started
0 lock struct(s), heap size 1128, 0 row lock(s)
---TRANSACTION 421376845869864, not started
0 lock struct(s), heap size 1128, 0 row lock(s)
---TRANSACTION 421376845868248, not started
0 lock struct(s), heap size 1128, 0 row lock(s)
---TRANSACTION 421376845867440, not started
0 lock struct(s), heap size 1128, 0 row lock(s)
---TRANSACTION 421376845866632, not started0 lock struct(s), heap size 1128, 0 row lock(s)
--------FILE I/O
--------I/O thread 0 state: waiting for completed aio requests (insert buffer thread)
I/O thread 1 state: waiting for completed aio requests (log thread)
I/O thread 2 state: waiting for completed aio requests (read thread)
I/O thread 3 state: waiting for completed aio requests (read thread)
I/O thread 4 state: waiting for completed aio requests (read thread)
I/O thread 5 state: waiting for completed aio requests (read thread)
I/O thread 6 state: waiting for completed aio requests (write thread)
I/O thread 7 state: waiting for completed aio requests (write thread)
I/O thread 8 state: waiting for completed aio requests (write thread)
I/O thread 9 state: waiting for completed aio requests (write thread)
Pending normal aio reads: [0, 0, 0, 0] , aio writes: [0, 0, 0, 0] ,ibuf aio reads:, log i/o's:, sync i/o's:
Pending flushes (fsync) log: 0; buffer pool: 0
1168 OS file reads, 1380 OS file writes, 701 OS fsyncs0.00 reads/s, 0 avg bytes/read, 0.00 writes/s, 0.00 fsyncs/s
-------------------------------------INSERT BUFFER AND ADAPTIVE HASH INDEX
-------------------------------------Ibuf: size 1, free list len 0, seg size 2, 0 merges
merged operations:insert 0, delete mark 0, delete 0
discarded operations:insert 0, delete mark 0, delete 0
Hash table size 34679, node heap has 2 buffer(s)
Hash table size 34679, node heap has 0 buffer(s)
Hash table size 34679, node heap has 0 buffer(s)
Hash table size 34679, node heap has 1 buffer(s)
Hash table size 34679, node heap has 0 buffer(s)
Hash table size 34679, node heap has 2 buffer(s)
Hash table size 34679, node heap has 3 buffer(s)
Hash table size 34679, node heap has 8 buffer(s)0.00 hash searches/s, 0.00 non-hash searches/s
---LOG
---Log sequence number          1352792225
Log buffer assigned up to    1352792225
Log buffer completed up to   1352792225
Log written up to            1352792225
Log flushed up to            1352792225
Added dirty pages up to      1352792225
Pages flushed up to          1352792225
Last checkpoint at           1352792225327 log i/o's done, 0.00 log i/o's/second
----------------------BUFFER POOL AND MEMORY
----------------------Total large memory allocated 0
Dictionary memory allocated 550711
Buffer pool size   8192
Free buffers       6892
Database pages     1284
Old database pages 493
Modified db pages  0
Pending reads      0
Pending writes: LRU 0, flush list 0, single page 0
Pages made young 0, not young 0
0.00 youngs/s, 0.00 non-youngs/s
Pages read 1139, created 145, written 840
0.00 reads/s, 0.00 creates/s, 0.00 writes/s
No buffer pool page gets since the last printout
Pages read ahead 0.00/s, evicted without access 0.00/s, Random read ahead 0.00/s
LRU len: 1284, unzip_LRU len: 0I/O sum[0]:cur[0], unzip sum[0]:cur[0]
--------------ROW OPERATIONS
--------------0 queries inside InnoDB, 0 queries in queue
0 read views open inside InnoDB
Process ID=10299, Main thread ID=139901376005888 , state=sleeping
Number of rows inserted 0, updated 0, deleted 0, read 274
0.00 inserts/s, 0.00 updates/s, 0.00 deletes/s, 0.00 reads/s
Number of system rows inserted 2, updated 479, deleted 0, read 129060.00 inserts/s, 0.00 updates/s, 0.00 deletes/s, 0.00 reads/s
----------------------------END OF INNODB MONITOR OUTPUT
============================1 row in set (0.01 sec)ERROR:
No query specified

3、显示数据库表中部分表

SHOW [FULL] TABLES [FROM db_name] [like_or_where]

(root@localhost) [(none)]> show tables from superdb like 'emp%';
+--------------------------+
| Tables_in_superdb (emp%) |
+--------------------------+
| emp                      |
| employees                |
+--------------------------+
2 rows in set (0.01 sec)(root@localhost) [(none)]> show full tables from superdb like 'emp%';
+--------------------------+------------+
| Tables_in_superdb (emp%) | Table_type |
+--------------------------+------------+
| emp                      | BASE TABLE |
| employees                | BASE TABLE |
+--------------------------+------------+
2 rows in set (0.04 sec)

4、显示表的字段信息

(root@localhost) [(none)]> desc superdb.emp;
+----------+--------------+------+-----+---------+----------------+
| Field    | Type         | Null | Key | Default | Extra          |
+----------+--------------+------+-----+---------+----------------+
| empno    | int unsigned | NO   | PRI | NULL    | auto_increment |
| ename    | varchar(15)  | YES  |     | NULL    |                |
| job      | varchar(10)  | YES  |     | NULL    |                |
| mgr      | int unsigned | YES  |     | NULL    |                |
| hiredate | date         | YES  |     | NULL    |                |
| sal      | decimal(7,2) | YES  |     | NULL    |                |
| comm     | decimal(7,2) | YES  |     | NULL    |                |
| deptno   | int unsigned | YES  | MUL | NULL    |                |
+----------+--------------+------+-----+---------+----------------+
8 rows in set (0.00 sec)-- OR (root@localhost) [(none)]> select * from information_schema.COLUMNS where table_schema='superdb' and table_name='emp';
+---------------+--------------+------------+-------------+------------------+----------------+-------------+-----------+--------------------------+------------------------+-------------------+---------------+--------------------+--------------------+--------------------+--------------+------------+----------------+---------------------------------+--------------------------------+-----------------------+--------+
| TABLE_CATALOG | TABLE_SCHEMA | TABLE_NAME | COLUMN_NAME | ORDINAL_POSITION | COLUMN_DEFAULT | IS_NULLABLE | DATA_TYPE | CHARACTER_MAXIMUM_LENGTH | CHARACTER_OCTET_LENGTH | NUMERIC_PRECISION | NUMERIC_SCALE | DATETIME_PRECISION | CHARACTER_SET_NAME | COLLATION_NAME     | COLUMN_TYPE  | COLUMN_KEY | EXTRA          | PRIVILEGES                      | COLUMN_COMMENT                 | GENERATION_EXPRESSION | SRS_ID |
+---------------+--------------+------------+-------------+------------------+----------------+-------------+-----------+--------------------------+------------------------+-------------------+---------------+--------------------+--------------------+--------------------+--------------+------------+----------------+---------------------------------+--------------------------------+-----------------------+--------+
| def           | superdb      | emp        | empno       |                1 | NULL           | NO          | int       |                     NULL |                   NULL |                10 |             0 |               NULL | NULL               | NULL               | int unsigned | PRI        | auto_increment | select,insert,update,references | 雇员编号                       |                       |   NULL |
| def           | superdb      | emp        | ename       |                2 | NULL           | YES         | varchar   |                       15 |                     60 |              NULL |          NULL |               NULL | utf8mb4            | utf8mb4_0900_ai_ci | varchar(15)  |            |                | select,insert,update,references | 雇员姓名                       |                       |   NULL |
| def           | superdb      | emp        | job         |                3 | NULL           | YES         | varchar   |                       10 |                     40 |              NULL |          NULL |               NULL | utf8mb4            | utf8mb4_0900_ai_ci | varchar(10)  |            |                | select,insert,update,references | 雇员职位                       |                       |   NULL |
| def           | superdb      | emp        | mgr         |                4 | NULL           | YES         | int       |                     NULL |                   NULL |                10 |             0 |               NULL | NULL               | NULL               | int unsigned |            |                | select,insert,update,references | 雇员对应的领导的编号           |                       |   NULL |
| def           | superdb      | emp        | hiredate    |                5 | NULL           | YES         | date      |                     NULL |                   NULL |              NULL |          NULL |               NULL | NULL               | NULL               | date         |            |                | select,insert,update,references | 雇员的雇佣日期                 |                       |   NULL |
| def           | superdb      | emp        | sal         |                6 | NULL           | YES         | decimal   |                     NULL |                   NULL |                 7 |             2 |               NULL | NULL               | NULL               | decimal(7,2) |            |                | select,insert,update,references | 雇员的基本工资                 |                       |   NULL |
| def           | superdb      | emp        | comm        |                7 | NULL           | YES         | decimal   |                     NULL |                   NULL |                 7 |             2 |               NULL | NULL               | NULL               | decimal(7,2) |            |                | select,insert,update,references | 奖金                           |                       |   NULL |
| def           | superdb      | emp        | deptno      |                8 | NULL           | YES         | int       |                     NULL |                   NULL |                10 |             0 |               NULL | NULL               | NULL               | int unsigned | MUL        |                | select,insert,update,references | 所在部门                       |                       |   NULL |
+---------------+--------------+------------+-------------+------------------+----------------+-------------+-----------+--------------------------+------------------------+-------------------+---------------+--------------------+--------------------+--------------------+--------------+------------+----------------+---------------------------------+--------------------------------+-----------------------+--------+
8 rows in set (0.01 sec)

5、显示表的索引信息

(root@localhost) [(none)]> show index from superdb.emp;
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+---------+------------+
| Table | Non_unique | Key_name | Seq_in_index | Column_name | Collation | Cardinality | Sub_part | Packed | Null | Index_type | Comment | Index_comment | Visible | Expression |
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+---------+------------+
| emp   |          0 | PRIMARY  |            1 | empno       | A         |          14 |     NULL |   NULL |      | BTREE      |         |               | YES     | NULL       |
| emp   |          1 | deptno   |            1 | deptno      | A         |           3 |     NULL |   NULL | YES  | BTREE      |         |               | YES     | NULL       |
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+---------+------------+
2 rows in set (0.01 sec)-- extended index 索引扩展信息(root@localhost) [(none)]> show extended index from superdb.emp;
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+---------+------------+
| Table | Non_unique | Key_name | Seq_in_index | Column_name | Collation | Cardinality | Sub_part | Packed | Null | Index_type | Comment | Index_comment | Visible | Expression |
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+---------+------------+
| emp   |          0 | PRIMARY  |            1 | empno       | A         |          14 |     NULL |   NULL |      | BTREE      |         |               | YES     | NULL       |
| emp   |          0 | PRIMARY  |            2 | DB_TRX_ID   | A         |        NULL |     NULL |   NULL |      | BTREE      |         |               | YES     | NULL       |
| emp   |          0 | PRIMARY  |            3 | DB_ROLL_PTR | A         |        NULL |     NULL |   NULL |      | BTREE      |         |               | YES     | NULL       |
| emp   |          0 | PRIMARY  |            4 | ename       | A         |        NULL |     NULL |   NULL | YES  | BTREE      |         |               | YES     | NULL       |
| emp   |          0 | PRIMARY  |            5 | job         | A         |        NULL |     NULL |   NULL | YES  | BTREE      |         |               | YES     | NULL       |
| emp   |          0 | PRIMARY  |            6 | mgr         | A         |        NULL |     NULL |   NULL | YES  | BTREE      |         |               | YES     | NULL       |
| emp   |          0 | PRIMARY  |            7 | hiredate    | A         |        NULL |     NULL |   NULL | YES  | BTREE      |         |               | YES     | NULL       |
| emp   |          0 | PRIMARY  |            8 | sal         | A         |        NULL |     NULL |   NULL | YES  | BTREE      |         |               | YES     | NULL       |
| emp   |          0 | PRIMARY  |            9 | comm        | A         |        NULL |     NULL |   NULL | YES  | BTREE      |         |               | YES     | NULL       |
| emp   |          0 | PRIMARY  |           10 | deptno      | A         |        NULL |     NULL |   NULL | YES  | BTREE      |         |               | YES     | NULL       |
| emp   |          1 | deptno   |            1 | deptno      | A         |           3 |     NULL |   NULL | YES  | BTREE      |         |               | YES     | NULL       |
| emp   |          1 | deptno   |            2 | empno       | A         |        NULL |     NULL |   NULL |      | BTREE      |         |               | YES     | NULL       |
+-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+---------+------------+
12 rows in set (0.01 sec)

6、显示表状态

SHOW TABLE STATUS

-- show table STATUS from superdb like 'emp%';
(root@localhost) [(none)]> show table STATUS from superdb like 'emp%' \G;
*************************** 1. row ***************************Name: empEngine: InnoDBVersion: 10Row_format: DynamicRows: 14Avg_row_length: 1170Data_length: 16384
Max_data_length: 0Index_length: 16384Data_free: 0Auto_increment: 7934Create_time: 2023-10-12 20:17:22Update_time: NULLCheck_time: NULLCollation: utf8mb4_0900_ai_ciChecksum: NULLCreate_options:Comment: 雇员信息表
*************************** 2. row ***************************Name: employeesEngine: InnoDBVersion: 10Row_format: DynamicRows: 107Avg_row_length: 153Data_length: 16384
Max_data_length: 0Index_length: 65536Data_free: 0Auto_increment: NULLCreate_time: 2023-10-12 20:17:22Update_time: NULLCheck_time: NULLCollation: utf8mb4_0900_ai_ciChecksum: NULLCreate_options:Comment: employees table. Contains 107 rows. References with departments,jobs, job_history tables. Contains a self reference.
2 rows in set (0.00 sec)ERROR:
No query specified

7、显示创建表的信息

show create table emp;

show create table emp;CREATE TABLE `emp` (`empno` int unsigned NOT NULL AUTO_INCREMENT COMMENT '雇员编号',`ename` varchar(15) DEFAULT NULL COMMENT '雇员姓名',`job` varchar(10) DEFAULT NULL COMMENT '雇员职位',`mgr` int unsigned DEFAULT NULL COMMENT '雇员对应的领导的编号',`hiredate` date DEFAULT NULL COMMENT '雇员的雇佣日期',`sal` decimal(7,2) DEFAULT NULL COMMENT '雇员的基本工资',`comm` decimal(7,2) DEFAULT NULL COMMENT '奖金',`deptno` int unsigned DEFAULT NULL COMMENT '所在部门',PRIMARY KEY (`empno`),KEY `deptno` (`deptno`),CONSTRAINT `emp_ibfk_1` FOREIGN KEY (`deptno`) REFERENCES `dept` (`deptno`)
) ENGINE=InnoDB AUTO_INCREMENT=7935 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci COMMENT='雇员信息表'

8、显示binlog信息

-- SHOW {BINARY | MASTER} LOGSshow binary LOGS; -- mysql8.0/8.4show master LOGS; -- mysql8.0show master status;     -- mysql8.0show binary log status; -- mysql8.4-- SHOW BINLOG EVENTS [IN 'log_name'] [FROM pos] [LIMIT [offset,] row_count]
(root@localhost) [(none)]> SHOW BINLOG EVENTS IN 'binlog.000030';
+---------------+-----+----------------+-----------+-------------+-----------------------------------+
| Log_name      | Pos | Event_type     | Server_id | End_log_pos | Info                              |
+---------------+-----+----------------+-----------+-------------+-----------------------------------+
| binlog.000030 |   4 | Format_desc    |         1 |         126 | Server ver: 8.0.28, Binlog ver: 4 |
| binlog.000030 | 126 | Previous_gtids |         1 |         157 |                                   |
+---------------+-----+----------------+-----------+-------------+-----------------------------------+
2 rows in set (0.01 sec)(root@localhost)[(none)]> SHOW BINLOG EVENTS IN 'binlog.000034';
+---------------+-----+----------------+-----------+-------------+--------------------------------------------------------------------------------------+
| Log_name      | Pos | Event_type     | Server_id | End_log_pos | Info                                                                                 |
+---------------+-----+----------------+-----------+-------------+--------------------------------------------------------------------------------------+
| binlog.000034 |   4 | Format_desc    |    853306 |         127 | Server ver: 8.4.0, Binlog ver: 4                                                     |
| binlog.000034 | 127 | Previous_gtids |    853306 |         158 |                                                                                      |
| binlog.000034 | 158 | Anonymous_Gtid |    853306 |         235 | SET @@SESSION.GTID_NEXT= 'ANONYMOUS'                                                 |
| binlog.000034 | 235 | Query          |    853306 |         331 | use `superdb`; ANALYZE TABLE employees                                               |
| binlog.000034 | 331 | Anonymous_Gtid |    853306 |         408 | SET @@SESSION.GTID_NEXT= 'ANONYMOUS'                                                 |
| binlog.000034 | 408 | Query          |    853306 |         550 | use `superdb`; ANALYZE TABLE employees update histogram on EMPLOYEE_ID,DEPARTMENT_ID |
| binlog.000034 | 550 | Anonymous_Gtid |    853306 |         627 | SET @@SESSION.GTID_NEXT= 'ANONYMOUS'                                                 |
| binlog.000034 | 627 | Query          |    853306 |         767 | use `superdb`; ANALYZE TABLE employees drop histogram on EMPLOYEE_ID,DEPARTMENT_ID   |
+---------------+-----+----------------+-----------+-------------+--------------------------------------------------------------------------------------+
8 rows in set (0.02 sec)(root@localhost)[(none)]> SHOW BINLOG EVENTS IN 'binlog.000034' from 127 limit 3;
+---------------+-----+----------------+-----------+-------------+----------------------------------------+
| Log_name      | Pos | Event_type     | Server_id | End_log_pos | Info                                   |
+---------------+-----+----------------+-----------+-------------+----------------------------------------+
| binlog.000034 | 127 | Previous_gtids |    853306 |         158 |                                        |
| binlog.000034 | 158 | Anonymous_Gtid |    853306 |         235 | SET @@SESSION.GTID_NEXT= 'ANONYMOUS'   |
| binlog.000034 | 235 | Query          |    853306 |         331 | use `superdb`; ANALYZE TABLE employees |
+---------------+-----+----------------+-----------+-------------+----------------------------------------+
3 rows in set (0.00 sec)

相关文章:

MySQL Show命令集

MySQL SHOW 命令 1、mysql shell 查看帮助show (rootlocalhost) [(none)]> \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 thos…...

倩女幽魂搬砖攻略:云手机自动托管搬砖刷本选哪家云手机?

欢迎来到《倩女幽魂手游》的世界&#xff0c;一个充满江湖恩怨的世界。在这个游戏中&#xff0c;你将扮演各个门派中的不同职业&#xff0c;踏上一段属于你自己的江湖之路。本攻略将为你详细介绍如何利用多开挂机搬砖&#xff0c;快速提升自己的实力&#xff0c;成为江湖中的一…...

php7.3安装phalcon扩展

php7安装3.4版本的phalcon扩展 适用于Centos6.x和Centos7.x系统&#xff0c;php使用7.1版本&#xff0c;wlnmp一键包已支持该扩展 phalcon扩展包地址&#xff1a;https://github.com/phalcon/cphalcon &#xff08;git clone 有可能连接不上&#xff09; 1、安装所需依赖&a…...

IIoT(智能物联网)的现状、应用及安全

近年来&#xff0c;物联网&#xff08;IoT&#xff09;作为推动现代公司和智能城市发展的一个范式&#xff0c;已经取得了显著的发展。IoT使得分布式设备&#xff08;如手机、平板电脑和计算机&#xff09;能够感知并从外部环境传输数据&#xff0c;以服务于最终用户。IoT的概念…...

YOLOv8_obb的训练、验证、预测及导出[旋转目标检测实践篇]

1.旋转目标检测数据集划分和配置 从上面得到的images和labels数据还不能够直接训练,需要按照一定的比例划分训练集和验证集,并按照下面的结构来存放数据,划分代码如下所示,该部分内容和YOLOv8的训练、验证、预测及导出[目标检测实践篇]_yolov8训练测试验证-CSDN博客是重复的…...

C语言实战:贪吃蛇(万字详解)

&#x1f4a1;目录 效果图 界面设计思路 1. 基本布局 2. 视觉元素 游戏机制设计 基本规则 游戏代码 前期准备 游戏代码详解 数据结构设计 宏定义 数据结构定义 函数原型&#xff08;详见后文&#xff09; 主函数代码 核心代码 Review 效果图 界面设计思路 1. 基…...

定时器更新界面,线程报错

项目场景&#xff1a; 在javafx框架下使用线程更新UI的时候&#xff0c;出现无法正常更新UI。 问题代码如下&#xff1a; package clock;import java.util.Calendar; import java.util.GregorianCalendar; import java.util.Timer; import java.util.TimerTask;import javaf…...

未来AI大模型的发展趋势

大家好&#xff0c;我是小悟 未来AI大模型的发展趋势无疑将是多元化、高效化、普及化以及人性化。随着技术的飞速进步&#xff0c;AI大模型将在各个领域中展现出更加广泛和深入的应用&#xff0c;成为推动社会进步的重要力量。 多元化是AI大模型发展的重要方向。随着数据量的…...

【JavaScript函数详解】Day04

JavaScript函数详解 JavaScript 基础 - 第4天笔记函数声明和调用声明&#xff08;定义&#xff09;调用 参数形参和实参参数默认值 返回值函数补充细节作用域全局作用域局部作用域变量的访问原则 匿名函数函数表达式立即执行函数 逻辑中断小知识&#xff08;转换为Boolean型&am…...

json和axion结合

目录 java中使用JSON对象 在pom.xml中导入依赖 使用 public static String toJSONString(Object object)把自定义对象变成JSON对象 json和axios综合案例 使用的过滤器 前端代码 响应和请求都是普通字符串 和 请求时普通字符串&#xff0c;响应是json字符串 响应的数据是…...

v1.2.70-FastJson的AutoType机制研究

v1.2.70-FastJson的AutoType机制研究 最近在对接Alexa亚马逊语音技能&#xff0c;Smart Home Skill Apis时&#xff0c;有一个配置的JSON字符串是这样的&#xff1a; { "capabilityResources": {"friendlyNames": [{"type": "asset",…...

老旧机子装linux——Xubuntu

目录 前言 正文 下载系统 ​编辑 制作系统盘&#xff1a; 安装界面 Xubuntu ​编辑 lubuntu 后语 前言 有两台电脑&#xff0c;一台装了Ubuntu22&#xff0c;一台装了debuntu。虽然debuntu界面与乌班图大体一样&#xff0c;但是编译器好像有点区别。由于机子为10年前的老…...

关于Redis中事务

事务的四个特性 Redis到底有没有原子性 Redis中的原子性不同于MySQL&#xff0c;相比于MySQL&#xff0c;Redis中的原子性几乎不值一提。 MySQL中的原子性&#xff0c;不仅仅是“要么全都执行&#xff0c;要么全都不执行”&#xff0c;它还保证了“一旦执行&#xff0c;结果…...

【数据分享】《中国文化文物与旅游统计年鉴》2022

最近老有同学过来询问《中国旅游年鉴》、《中国文化文物统计年鉴》、《中国文化和旅游统计年鉴》、《中国文化文物与旅游统计年鉴》&#xff0c;这四本年年鉴的关系以及怎么获取这四本年鉴。今天就在这里给大家分享一下这四本年鉴的具体情况。 实际上2018年&#xff0c;为适应…...

设计模式及其在软件开发中的应用

一、技术难点 设计模式在软件开发中扮演着至关重要的角色&#xff0c;但它们的应用也伴随着一系列技术难点。 模式选择与识别&#xff1a;在实际项目中&#xff0c;正确识别和选择合适的设计模式是一个挑战。不同的设计模式适用于不同的场景&#xff0c;错误的选择可能导致系统…...

LeetCode72编辑距离

题目描述 解析 一般这种给出两个字符串的动态规划问题都是维护一个二维数组&#xff0c;尺寸和这两个字符串的长度相等&#xff0c;用二维做完了后可以尝试优化空间。这一题其实挺类似1143这题的&#xff0c;只不过相比1143的一种方式&#xff0c;变成了三种方式&#xff0c;就…...

竞拍商城系统源码后端PHP+前端UNIAPP

下载地址&#xff1a;竞拍商城系统源码后端PHP前端UNIAPP...

千益畅行,共享旅游卡,灵活同行,畅游无忧的全方位解析

千益畅行&#xff0c;共享旅游卡&#xff0c;满足您多样化的同行出行需求 近期&#xff0c;关于千益畅行共享旅游卡的咨询热度不减&#xff0c;尤其是关于其同行人数的限制问题。为了给大家一个清晰的解答&#xff0c;我们深入探讨了该旅游卡的特点和优势。 千益畅行共享旅游…...

Web IDE 在线编辑器综合实践(Web IDE 技术探索 三)

前言 前面两篇文章&#xff0c;我们简单讲述了 WebContainer/api 、Terminal 的基本使用&#xff0c;离完备的在线代码编辑器就差一个代码编辑了。今天通过 monaco editor &#xff0c;来实现初级代码编辑功能&#xff0c;讲述的是整个应用的搭建&#xff0c;并不单独针对monac…...

Less is more VS 精一 [生活感悟]

"Less is More”和王阳明的“精一”思想确实有相似之处。 王阳明的“精一”思想强调的是专注于一件事&#xff0c;将其做到极致&#xff0c;这与"Less is More”中提倡的通过减少数量来提高质量的理念不谋而合。两者都强调了专注和深度的重要性&#xff0c;而不是追…...

函数的概念及图像

注&#xff1a; 判断两函数是否相同&#xff0c;只看定义域和对应法则。 1. 函数的定义 一般的&#xff0c;在一个变化过程中有两个变量 x&#xff0c;y。如果对于x在某个变化范围内的每一个确定值&#xff0c;按照某个对应法则&#xff0c;都有唯一确定的值y和他对应。那么y就…...

Linux中Apache网站基于Http服务的访问限制(基于地址/用户)

&#x1f3e1;作者主页&#xff1a;点击&#xff01; &#x1f468;‍&#x1f4bb;Linux高级管理专栏&#xff1a;点击&#xff01; ⏰️创作时间&#xff1a;2024年6月3日11点44分 &#x1f004;️文章质量&#xff1a;95分 为了更好地控制对网站资源的访问&#xff0c;可…...

滚动条详解:跨平台iOS、Android、小程序滚动条隐藏及自定义样式综合指南

滚动条是用户界面中的图形化组件&#xff0c;用于指示和控制内容区域的可滚动范围。当元素内容超出其视窗边界时&#xff0c;滚动条提供可视化线索&#xff0c;并允许用户通过鼠标滚轮、触屏滑动或直接拖动滑块来浏览未显示部分&#xff0c;实现内容的上下或左右滚动。它在保持…...

06 Linux 设备驱动模型

1、Overview Linux-2.6 引入的新的设备管理机制 - kobject 降低设备多样性带来的 Linux 驱动开发的复杂度,以及设备热拔插处理、电源管理等将硬件设备归纳、分类,然后抽象出一套标准的数据结构和接口驱动的开发,就简化为对内核所规定的数据结构的填充和实现驱动模型是 Linu…...

检测五个数是否一样的算法

目录 算法算法的输出与打印效果输出输入1输入2 打印打印1打印2 算法的流程图总结 算法 int main() {int arr[5] { 0 };int i 0;int ia 0;for (i 0; i < 5; i) { scanf("%d", &arr[i]); }for (i 1; i < 5; i) {if (arr[0] ! arr[i]) {ia 1;break;} }…...

java 原生http服务器 测试JS前端ajax访问实现跨域传post数据

后端 java eclipse 字节流转字符 package Httpv3;import com.sun.net.httpserver.Headers; import com.sun.net.httpserver.HttpExchange; import com.sun.net.httpserver.HttpHandler; import com.sun.net.httpserver.HttpServer;import java.io.IOException; import java.i…...

【机器学习】消息传递神经网络(MPNN)在分子预测领域的医学应用

1. 引言 1.1. 分子性质预测概述 分子性质预测是计算机辅助药物发现流程中至关重要的任务之一&#xff0c;它在许多下游应用如药物筛选和药物设计中发挥着核心作用&#xff1a; 1.1.1. 目的与重要性&#xff1a; 分子性质预测旨在通过分子内部信息&#xff08;如原子坐标、原…...

Python Flask实现蓝图Blueprint配置和模块渲染

Python基础学习&#xff1a; Pyhton 语法基础Python 变量Python控制流Python 函数与类Python Exception处理Python 文件操作Python 日期与时间Python Socket的使用Python 模块Python 魔法方法与属性 Flask基础学习&#xff1a; Python中如何选择Web开发框架&#xff1f;Pyth…...

Vue10-事件修饰符

一、示例&#xff1a;<a>标签不执行默认的跳转行为 1-1、方式一 <a href"http://www.baidu.com" onclick"event.preventDefault();">点击我</a> 1-2、方式二 1-3、方式三&#xff1a;事件修饰符 二、Vue的六种事件修饰符 2-1、prevent&…...

oracle中如何查询特定日期?

1. select last_day(to_date(20230101,YYYYMMDD)) from dual; select last_day(to_date(V_END_DATE,YYYYMMDD)) from dual; --查询任意一天 当月的最后一天 2. select to_char(to_date(20230101,YYYYMMDD)-1,YYYYMMDD) INTO V_START_DATE FROM DUAL; select to_char(to_dat…...

做资源下载网站用什么工具/做运营需要具备什么能力

可以通过使用 CCMSetup.exe 和 /Uninstall 开关从计算机卸载 Configuration Manager 2007 客户端软件。在单台计算机上从命令提示符运行 CCMSetup.exe 或使用 Configuration Manager 2007 软件分发以通过使用脚本在计算机集合上卸载客户端。 方法如下&#xff1a; 1、以管理员身…...

wordpress中国/汕头网站关键词推广

1.注释注释是为了解释某些代码所加的文字&#xff0c;类似批注&#xff0c;提高程序可读性。编译时&#xff0c;编译器直接跳过&#xff0c;不会 变成字节码文件。单行注释&#xff1a;以"//"开头&#xff0c;这一行"//"后面均为注释&#xff0c;换行即结束…...

腾讯建站官网/陕西网站建设制作

语法弄了半天发出来备份个 --新增影城微信支付方式 create or replace procedure insert_cinema_weixin(cinema_id in varchar2 ) as cinema_name_tmp varchar2(400);begin--判断传入值是否合法if(cinema_id is null or length(cinema_id) <2) thenreturn;end if; …...

企业备案网站可以做论坛吗/百度下载安装官方下载

CodeIgniter 的错误处理1.CI在引导文件index.php中设置了“执行环境常量 EVIROMENT”&#xff0c;在值为“development”打开php的全部报错。2.在Common文件中&#xff0c;CI载入了Exception类&#xff0c;该类可以让用户使用show_error等函数主动输出错误。3.在Common文件&…...

石家庄建站外贸网站/外链购买平台

package com.sq;import java.io.File; import java.nio.file.Path; import java.nio.file.Paths;import org.junit.Test;/*** 1.jdk 7.0时&#xff0c;引入了 Path、Paths、Files 三各类 2.此三各类声明在&#xff1a;java.nio.file 包下。 3.Path 可以看作是 java.io.File 类的…...

深圳做网站龙华新科/百度关键词查询

一、日常关注的问题1、我们的日志生成速度&#xff1f;1、每天生成多少日志、产生多少redo logmysql> show global status like Innodb_os_log_written;-------------------------------| Variable_name | Value |-------------------------------| Innodb_os_log_written |…...