|
|
楼主 |
发表于 2020-5-7 17:00:01
|
显示全部楼层
mysql> use mysql
0 I' ^8 b4 f$ ]# ]& y* S# ^8 zReading table information for completion of table and column names
8 `! S P4 b5 g, G- XYou can turn off this feature to get a quicker startup with -A
$ R4 L+ H- |1 O S6 j* d/ QDatabase changed9 a! P4 f% E* z! Y! _
mysql> select Host,User from user;
" B3 H+ b. v* C% p5 B* E+-------------------+------------+
8 t7 U: _0 T) X( Q/ `3 m/ X| Host | User |0 z) S* _. E8 d% @
+-------------------+------------+" B4 F* b- b+ q5 A+ E& W
| 127.0.0.1 | root |
/ h- j. L( _5 t| localhost | |
- _, I/ Z% t9 Q| localhost | root |
# v* t" U4 v$ J; g) M/ v, q' H| localhost.example | |
& X& x* S. J' a( |7 M( b7 t9 l) s| localhost.example | root |
7 b' z' M7 A+ C. K$ G/ b1 X" @+-------------------+------------+. v+ K. g" D* ^6 m
11 rows in set (0.00 sec)- V4 e* L- J! y1 O* @& w
mysql> delete from user where Host='localhost.example';
# b' p E3 h9 N( G9 j+ x6 v" LQuery OK, 2 rows affected (0.00 sec)
5 m; H J0 P0 |' _5 ]! S% f+ ~( imysql> select Host,User from user;
' y& B A' z; i4 m9 s) G+--------------+------------+3 ?0 V0 z7 u m! ~" ?$ g0 p4 z/ x
| Host | User |' I7 J( a4 f+ t
+--------------+------------+
, E" k8 N6 ~. B$ I7 y| 127.0.0.1 | root |1 g- X7 z* }" H+ k) I9 \3 \; f; [; {& `
| localhost | |: Z3 H- X V/ k% w
| localhost | root |* c. E8 V' O& e
+--------------+------------+
( [- I# i$ L" l' N- w9 rows in set (0.00 sec)! L x# ~. X( l7 [& B
mysql> delete from user where User='' ;
o* ?) R. l( Q: d. Z8 z: ^% e$ sQuery OK, 1 row affected (0.00 sec). K# ^0 Q2 U+ V) w7 P
mysql> select Host,User from user;
5 |* Z2 V, A! X1 O5 m" t+--------------+------------+0 [4 y2 g) z4 L: P, v+ s/ B, u. t
| Host | User |7 t ^, l0 ]9 @0 H3 V
+--------------+------------+
& d+ s' C8 O) f* D7 X, || 127.0.0.1 | root |/ G% @+ ]& U1 t: I; H& |5 z
| localhost | root |& ]' \. u8 O) X
+--------------+------------+
+ D- Q/ ^8 X, f# J0 k @5 h8 rows in set (0.00 sec)3 s, @) c, N2 @ f! H
|
|