Article 6GSMQ [mysql] [ODBC 8.2(w) Driver]Wrong or unknown protocol

[mysql] [ODBC 8.2(w) Driver]Wrong or unknown protocol

by
jonaskellens
from LinuxQuestions.org on (#6GSMQ)
Hello

I have a problem connecting to my MySQL database using unixODBC.

When I test the connection, I get :
Code:[root@ig0 admin]# echo "select 1" | isql -v my-connector
[S1000][unixODBC][MySQL][ODBC 8.2(w) Driver]Wrong or unknown protocol
[ISQL]ERROR: Could not SQLConnectI'm new to this.
I don not find many help on Google for this "Driver]Wrong or unknown protocol", except a MySQL bug.

all the system info :

Code:[root@ig0 admin]# cat /etc/centos-release
CentOS Linux release 7.9.2009 (Core)Code:[root@ig0 admin]# mysql --version
mysql Ver 14.14 Distrib 5.6.51, for Linux (x86_64) using EditLine wrapperCode:[root@ig0 admin]# odbcinst -j
unixODBC 2.3.1
DRIVERS............: /etc/odbcinst.ini
SYSTEM DATA SOURCES: /etc/odbc.ini
FILE DATA SOURCES..: /etc/ODBCDataSources
USER DATA SOURCES..: /root/.odbc.ini
SQLULEN Size.......: 8
SQLLEN Size........: 8
SQLSETPOSIROW Size.: 8Code:[root@ig0 admin]# cat /etc/odbcinst.ini
[PostgreSQL]
Description=ODBC for PostgreSQL
Driver=/usr/lib/psqlodbcw.so
Setup=/usr/lib/libodbcpsqlS.so
Driver64=/usr/lib64/psqlodbcw.so
Setup64=/usr/lib64/libodbcpsqlS.so
FileUsage=1

[MySQL]
Description=ODBC for MySQL
DRIVER=/usr/lib64/libmyodbc8w.so
UsageCount=1

[MySQL ODBC 8.2 Unicode Driver]
DRIVER=/usr/lib64/libmyodbc8w.so
UsageCount=1

[MySQL ODBC 8.2 ANSI Driver]
DRIVER=/usr/lib64/libmyodbc8a.so
UsageCount=1Code:[root@ig0 admin]# cat /etc/odbc.ini
[my-connector]
Description = MySQL connection to database
Driver = MySQL
Database = db01
Server = 11.22.33.44
UserName = user
Password = pwd
Port = 3306
Socket = /var/lib/mysql/mysql.sock
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments