USEGEAR

导航

win下的PG12安装plpython3u

Python实在是太牛B。在pg中使用函数等使用Python,是否会上天呢?

在网上折腾好久,关于如何安装plpython3u,五花八门云里雾里。

洒家的过程如下:

1、安装Python。注意64和32的问题。应该你同时需要64和32。更要注意Pg版本是对应的Python版本。通过depends22可以查看pg\xx\lib\PLPYthon.dll的依赖库选择版本(建议)

 

 

2、安装PostgreSQL。特别注意扩展附件的安装。睁大眼睛选择语言包。由于扩展安装延时古怪,因此要有耐心等待。

3、在数据库管理器中用CREATE EXTENSION plpython3u执行。如果出现下面界面,恭喜你成功了。

 

 

Procedural Languages PG12

The procedural languages pl/Perl, pl/Python and pl/Tcl are included in this distribution of PostgreSQL. 
The server has been built using the LanguagePack community distributions of those language interpreters.

To use any of the these languages from within PostgreSQL,
download and install the appropriate interpreters and ensure they are included in the PATH variable under which the database server will be started.
The versions used are shown below - newer minor (bugfix) releases may also work, but have not been tested: Perl 5.26 Python 3.7 Tcl 8.6

 

 

 恭喜,成功了!

posted on 2022-04-27 11:12  USEGEAR  阅读(412)  评论(0编辑  收藏  举报