VScode中链接数据库

安装mysql模块

image-20220417111626621

创建数据库和表并输入内容

image-20220417111656187

image-20220417111703619

image-20220417111711895

注意端口号还有密码

image-20220417111725819

加入条件查找

image-20220417111734172

image-20220417111750525

image-20220417111758361

报错

Client does not support authentication protocol requested by server; consider upgrading MySQL client'

解决办法

image-20220417112005280

1、use mysql;

2、alter user 'root'@'localhost' identified with mysql_native_password by '********';

3、flush privileges;

posted @ 2022-04-17 11:25  shushengyuan  阅读(795)  评论(0编辑  收藏  举报