下列选项中关于数据库的描述错误的是()。
A: ALTERUSER’root’@’localhost’IDENTIFIEDBY’000’
B: SETPASSWORDFOR’root’@’localhost’=’000’
C: mysqladmin–uroot-ppassword000
D: 以上答案都不正确
A: ALTERUSER’root’@’localhost’IDENTIFIEDBY’000’
B: SETPASSWORDFOR’root’@’localhost’=’000’
C: mysqladmin–uroot-ppassword000
D: 以上答案都不正确
举一反三
- 连接 MySQL 数据库的正确方法是( ) A: mysql_open("localhost","root","root"); B: mysql_connect("localhost","root","root"); C: connect_mysql("localhost","root","root"); D: dbopen("localhost","root","root");
- 下列可以将mysql的本地root用户的密码修改为‘123’的是() A: setpasswordforroot@'localhost'=password('123'); B: updatemysql.usersetpassword=password('123')whereuser='root'andhost='localhost'; C: selectpasswordforroot@'localhost'=password('123'); D: createuserroot@'localhost'identifiedby'123';
- 实现将root用户的密码修改为'1111'的语句,正确的是() A: alter user 'root'@'localhost' identified by ‘1111’; B: alter user 'root'@'localhost' identified by 1111; C: alter user 'root'@'localhost' =‘1111’; D: set user 'root'@'localhost' =‘1111’;
- 请看下面的代码,数据库关闭指令将关闭哪个链接标识?( ) <?php $link=mysql_connect("localhost","root",""); $link2=mysql_connect("localhost","root",""); mysql_close(); ?>
- 请看代码,数据库关闭指令将关闭哪个连接标识?( )<;?$link1 =mysql_connect("localhost","root","");$link2 =mysql_connect("localhost","root","");mysql_close();?>; A: $link1 B: $link2 C: 全部关闭 D: 报错