12-09
12-09
12-09
12-09
12-09
12-09
12-09
12-09
12-09
12-09
12-09
12-09
ADADADADAD
mysql数据库 时间:2024-12-25 09:56:16
作者:文/会员上传
12-09
12-09
12-09
12-09
12-09
12-09
12-09
12-09
12-09
12-09
12-09
12-09
由以下示例得出,客户端连接MySQL时执行语句包括如下过程:1.认证是否可以登录MySQL服务端。2.语法分析判断执行语句是否合法,无语句错误。3.权限分析判断执行语句,是否有对目标的
以下为本文的正文内容,内容仅供参考!本站为公益性网站,复制本文以及下载DOC文档全部免费。
由以下示例得出,客户端连接MySQL时执行语句包括如下过程:
1.认证
是否可以登录MySQL服务端。
2.语法分析
判断执行语句是否合法,无语句错误。
3.权限分析
判断执行语句,是否有对目标的相关权限。
4.语义分析
判断是否存在相应的表和字段
5.优化执行
优化器优化SQL语句后,执行并返回结果。
1)mysql -utest -h227.0.0.1 -p -P3306 -perrorWarning: Using a password on the command line interface can be insecure.ERROR 1045 (28000): Access denied for user 'test'@'127.0.0.1' (using password: YES)mysql> show grants;+--------------------------------------------------------------------------+| Grants for test@127.0.0.1|+--------------------------------------------------------------------------+| GRANT USAGE ON *.* TO 'test'@'127.0.0.1' IDENTIFIED BY PASSWORD <secret> || GRANT SELECT ON `test`.* TO 'test'@'127.0.0.1' |+--------------------------------------------------------------------------+2 rows in set (0.00 sec)mysql> mysql> 2)mysql> select *** from test.t;ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '** from test.t' at line 1mysql> 3)mysql> select * from a.t;ERROR 1142 (42000): SELECT command denied to user 'test'@'127.0.0.1' for table 't'mysql> mysql> 4)mysql> select * from test.t;ERROR 1146 (42S02): Table 'test.t' doesn't existmysql> mysql>
11-20
11-19
11-20
11-20
11-20
11-19
11-20
11-20
11-19
11-20
11-19
11-19
11-19
11-19
11-19
11-19