mychem / mychem-code

Mychem is an extension for MySQL that makes possible to use cheminformatics functions within SQL queries.
GNU General Public License v2.0
21 stars 14 forks source link

FUNCTION OPENBABEL_VERSION does not exist #5

Closed rapodaca closed 4 years ago

rapodaca commented 8 years ago

Edit: After poking around some more, it looks like the file src/mychemdb.sql needs to be run manually to add the user defined functions:

$ mysql -u -p src/mychemdb.sql

Running this command adds all Mychem functions, which appear on quick examination to work as expected.

On a clean Ubuntu-14.04.3 64-bit host, I wanted to confirm that new functions were available:

mysql> select OPENBABEL_VERSION();

and got an error:

ERROR 1305 (42000): FUNCTION OPENBABEL_VERSION does not exist

I get a similar error with MYCHEM_VERSION. There don't appear to be any user defined functions:

mysql> select * from mysql.func;
Empty set (0.00 sec)

My installation procedure from a clean OS was:

$ sudo apt-get install mysql-server cmake openbabel libopenbabel-dev libmysqlclient-dev
$ sudo apt-get install build-essential git pkg-config
$ git clone https://github.com/mychem/mychem-code.git
$ cd mychem-code
$ mkdir build
$ cd build
$ cmake ..
$ make
$ sudo make install

It appears the files were installed as intended:

$ ls /usr/lib/mysql/plugin
adt_null.so          libdaemon_example.so  qa_auth_client.so
auth.so              libmychem.so          qa_auth_interface.so
auth_socket.so       libmychem.so.0        qa_auth_server.so
auth_test_plugin.so  libmychem.so.0.9.2    semisync_master.so
ha_example.so        mypluglib.so          semisync_slave.so

Open Babel version was 2.3.2, MySQL 5.5.44.

I haven't tried to install Mychem recently, and so may be missing something important. Any ideas?

fredrikw commented 8 years ago

Hi, After the installation, you need to run mysql -u user -p < ../src/mysqldb.sql to install the functions into MySQL. Kind regards, Fredrik

Pansanel commented 8 years ago

Hi, Did you check the configuration of AppArmor? http://mychem.sourceforge.net/doc/apbs02.html Cheers, Jerome

Pansanel commented 4 years ago

I close the bug, as I did not received any answer from the user.