Hi Tiangan:
1. Mysql client library's license is GPL, which is not compatible with Apache License, so we should remove it finally. 2. Put Oracle's ODBC library in our thirdparty still meet the license issue, we can consider providing it outside the code base. -- 此致!Best Regards 陈明雨 Mingyu Chen Email: chenmin...@apache.org 在 2020-08-18 11:19:25,"吴天干" <wutian...@gmail.com> 写道: >1、For compatibility consideration, I suggest that ODBC scannode should >not support mysql odbc. I think users can access MySQL with MySQL client >library and Oracle with ODBC at the same time. >2、For the convenience of users, I suggest that we put some Oracle's ODBC >dynamic library into our third party(we can choose several commonly used >versions based centos) to facilitate users' direct use and reduce the >user's adaptation time. > >陈明雨 <morning...@163.com> 于2020年8月17日周一 下午8:21写道: > >> Nice Work. >> >> >> For the old mysql external table, I think we can ensure compatibility >> after the upgrade through metadata conversion. >> >> >> 1. Users can install Mysql driver in advance before upgrading. >> 2. Metadata can be modified during replay, converting MySQLTable to >> OdbcTable >> 3. We can add a FE configuration to add the default driver attribute to >> the converted OdbcTable. >> >> >> >> >> -- >> >> 此致!Best Regards >> 陈明雨 Mingyu Chen >> >> Email: >> chenmin...@apache.org >> >> >> >> >> 在 2020-08-17 17:30:20,"Lee Happen" <happen...@hotmail.com> 写道: >> >> > I understand that these are two independent libraries, and there should >> be >> > no mutual influence. Can you put some more detailed error messages? Is it >> > caused by relying on different versions of tripartite libraries? >> >> >> >> if we use compile option WITH_MYSQL. when we start odbc connect to mysql >> will cause BE core like: >> >> >> >> >> >> >> > ODBC Driver needs user install MySQL ODBC driver in its Backend machine. >> So >> > this is not something we can do. >> > I suggest that we support both at first, but we recommend that users >> > replace the old one with the new one. >> > Because the cost of creating external tables is extremely low, this is >> also >> > good for users. >> >> >> before we solve the conflict between MySQL ODBC Driver with static library >> mysql-server-mysql-5.7.18. it seems default to keep both old MySQL external >> table and odbc table connect MySQL. >> >> >> If it is difficult to solve conflict core problem, should we ask user to >> prepare odbc env of mysql driver before update Doris version. And change >> the old MySQL external to newest ODBC Table automatic in meta data. >> >> Best Wish >> >> Happen Lee >> >> >> From: Zhao Chun <zh...@apache.org> >> Sent: August 17, 2020 8:22 >> To: dev@doris.apache.org <dev@doris.apache.org> >> Subject: Re: [Proposal] Support ODBC Scan Node for Doris >> >> Wonderful proposal! >> >> Some comments inlined. >> >> Thanks, >> Zhao Chun >> >> >> Lee Happen <happen...@hotmail.com> 于2020年8月17日周一 下午4:00写道: >> >> > >> > Motivation >> > >> > At present, many customers need to access the external table through >> > Doris, but Doris only supports accessing the external table of MySQL at >> > present. This problem makes it difficult for users of other databases to >> > use Doris. >> > >> > Open Database Connectivity (ODBC) is a standard application programming >> > interface for accessing database management systems: >> > https://en.wikipedia.org/wiki/Open_Database_Connectivity >> > >> > So should we support ODBC Scan node as a general external table access >> > method, it is provided to users. user can use Driver Manager of ODBC to >> > determine the databases that need to be accessed. >> > >> > It can bring us the following benefits: >> > >> > 1. First, Doris can eazily support a variety of different databases as >> > external table, likes: Oracle, PostgreSQL, SQLServer. Not only RDMS, ODBC >> > also support some NoSQL database. likes: Redis, MongoDB. >> > >> > 1. ODBC help Doris have a unified development interface instead of >> > focusing on the connection implementation of different databases. >> > >> > 2. UNIX ODBC is a static library based on LGPL, which can avoid the >> > commercial risk of using different database client APIs >> > >> > How To Use >> > >> > It is very similar to the previous use of MySQL external table. The table >> > creation statement is as follows. >> > >> > CREATE EXTERNAL TABLE `baseall_oracle` ( >> > `k1` decimal(9, 3) NOT NULL COMMENT "", >> > `k2` char(10) NOT NULL COMMENT "", >> > `k3` datetime NOT NULL COMMENT "", >> > `k5` varchar(20) NOT NULL COMMENT "", >> > `k6` double NOT NULL COMMENT "" >> > ) ENGINE=ODBC >> > PROPERTIES ( >> > "host" = "192.168.1.2", >> > "port" = "4234", >> > "user" = "happenlee", >> > "password" = "happenlee", >> > "database" = "happen", >> > "table" = "baseall", >> > "driver" = "Oracle 19 ODBC driver", >> > "type" = "oracle" >> > ); >> > >> > >> > Noted that it needs to add some additional info: >> > >> > * type: To identify which database the table belongs to. For >> different >> > databases, there are some differences in ODBC connection and query. >> > >> > * driver: To identify which odbc driver the table use. Use should >> > installed proper driver and config it in be/conf/odbcinst.ini like: >> > >> > # Example driver definitions >> > >> > # Driver from the postgresql-odbc package >> > # Setup from the unixODBC package >> > [PostgreSQL] >> > Description = ODBC for PostgreSQL >> > Driver = /usr/lib/psqlodbc.so >> > Setup = /usr/lib/libodbcpsqlS.so >> > Driver64 = /usr/lib64/psqlodbc.so >> > Setup64 = /usr/lib64/libodbcpsqlS.so >> > FileUsage = 1 >> > >> > >> > # Driver from the mysql-connector-odbc package >> > # Setup from the unixODBC package >> > [MySQL ODBC 8.0 Unicode Driver] >> > Description = ODBC for MySQL >> > Driver = /home/happen/mysql/mysql_odbc_rpm/usr/lib64/libmyodbc8w.so >> > FileUsage = 1 >> > >> > [Oracle 19 ODBC driver] >> > Description=Oracle ODBC driver for Oracle 19 >> > Driver=/usr/lib/oracle/19.8/client64/lib/libsqora.so.19.1 >> > Setup= >> > FileUsage= >> > CPTimeout= >> > CPReuse= >> > >> > >> > >> > Implementation >> > >> > 1. First, we should add third party static library of Unix ODBC. >> > >> > 2. Second,Modify thrift file to determine the interface of ODBC scan >> > node. like: >> > >> > 1. Modify the code of be part, implementation ODBC_SCAN_NODE and >> > ODBC_SCANNER >> > >> > 2. Modify the code of FE part to support adding external tables of >> ODBC >> > engine. >> > >> > Some Problem Need To Talk >> > >> > 1. Now the odbc driver of mysql have a function library conflict with >> > mysql-server-mysql-5.7.18,which may cause core of BE. So we should >> disable >> > WITH_MYSQL compile options,when we need to use ODBC_SCAN_NODE to connect >> > mysql. >> > >> >> I understand that these are two independent libraries, and there should be >> no mutual influence. Can you put some more detailed error messages? Is it >> caused by relying on different versions of tripartite libraries? >> >> >> > 2. odbc scan node should support old external table of MySQL. >> > >> ODBC Driver needs user install MySQL ODBC driver in its Backend machine. So >> this is not something we can do. >> I suggest that we support both at first, but we recommend that users >> replace the old one with the new one. >> Because the cost of creating external tables is extremely low, this is also >> good for users. >> >> >> > >> > >> > Best Wish >> > >> > HappenLee >> > >> > >> > >>