达梦数据库odbc配置

达梦数据库odbc配置

技术教程gslnedu2025-03-10 13:16:233A+A-

检查gcc等

rpm -aq|grep gcc

开始安装ODBC-2.3.0:

tar -xvf unixODBC-2.3.0.tar.gz

cd unixODBC-2.3.0/

./configure --enable-gui=no

make && make install

odbc_config --version

查看 odbc 配置文件路径:

odbcinst -j


之后要编写请求达梦数据库的配置文件

cd /usr/local/etc/

修改这个目录下的odbc.ini 和 odbcinst.ini两个文件:

odbc.ini

[dm8]

Description = DM ODBC DSN

Driver = DM8 ODBC DRIVER

SERVER = localhost

UID = SYSDBA

PWD = dameng123

TCP_PORT = 5236


odbcinst.ini

[DM8 ODBC DRIVER]

Description = ODBC DRIVER FOR DM8

Driver = /dm8/bin/libdodbc.so



测试连接:

需要切换到dmdba

su - dmdba

isql dm8

select * from v$database;

点击这里复制本文地址 以上内容由朽木教程网整理呈现,请务必在转载分享时注明本文地址!如对内容有疑问,请联系我们,谢谢!
qrcode

朽木教程网 © All Rights Reserved.  蜀ICP备2024111239号-8