1.打开VS Code拓展,搜索postgresql,这时就可以看到在线的支持postgresql的插件,这里我选择的第一个插件(下载量最多的);


2.安装postgresql插件,安装完成之后,在左侧就可以看到插件图标;

3.点击插件,输入连接地址、用户、密码、端口等建立数据库连接(本地已经创建连接,点击 + 添加新的连接);









3.连接上以后测试数据及结果如下:
create table test (id int primary key, name varchar, create_date timestamp );
select * from test;
insert into test values (1, '001', now());
insert into test values (2, '002', now());
select * from test;

4.Mysql也是类似,详情可参考:Vscode上使用SQL
到此这篇关于Visual Studio Code(VS Code)查询PostgreSQL拓展安装的文章就介绍到这了,更多相关VS Code查询PostgreSQL内容请搜索脚本之家以前的文章或继续浏览下面的相关文章希望大家以后多多支持脚本之家!
您可能感兴趣的文章:- postgresql 查询字符串中是否包含某字符的操作
- PostgreSQL 慢查询SQL跟踪操作
- PostgreSQL 实现子查询返回多行的案例
- PostgreSQL 实现给查询列表增加序号操作
- 基于postgresql查询某个字段属于哪个表的说明
- 基于postgreSql 常用查询小结