Discussion:
MySQL from Octave
Nick5
2008-03-30 20:03:21 UTC
Permalink
I have tried all sorts of ways to connect to mysql. Has someone written a
"how to" for this?

I am trying to switch from matlab to octave - but I can't get this to work.

I used mym on matlab but I can't get it to compile for octave. I'm using XP
- though I might switch to Ubuntu if I can get octave working.

I've found a lot of people asking the same question - but no answer that
seems to work.

Thanks.
--
View this message in context: http://www.nabble.com/MySQL-from-Octave-tp16386545p16386545.html
Sent from the Octave - General mailing list archive at Nabble.com.
Xavier Delacour
2008-03-31 16:54:00 UTC
Permalink
Have you tried the "database" package in octave-forge? It connects to
mysql and some other databases.

It was added recently, so you'll need to download octave-forge via SVN
to get it. Also it hasn't been tested on Windows, so Ubuntu is
probably the fastest way to get up and running. Though Windows
integration shouldn't be particularly painful, it just hasn't been
done.

There is a slightly older version of the package, and more info here:
http://octave-swig.sourceforge.net/octave-db.html

Xavier
Post by Nick5
I have tried all sorts of ways to connect to mysql. Has someone written a
"how to" for this?
I am trying to switch from matlab to octave - but I can't get this to work.
I used mym on matlab but I can't get it to compile for octave. I'm using XP
- though I might switch to Ubuntu if I can get octave working.
I've found a lot of people asking the same question - but no answer that
seems to work.
Thanks.
--
View this message in context: http://www.nabble.com/MySQL-from-Octave-tp16386545p16386545.html
Sent from the Octave - General mailing list archive at Nabble.com.
_______________________________________________
Help-octave mailing list
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Xavier Delacour
2008-03-31 21:37:46 UTC
Permalink
(cc'ing help-octave)
Thanks for the reply.
Yes I tried this - I downloaded database-1.0.tar.gz and tried 'pkg
octave-3.0.0.exe:5> pkg install database-1.0.tar.gz
./configure: strings: command not found
swig error : Unrecognized option -octave
Use 'swig -help' for available options.
configure: error: swig doesn't support octave modules
You either need the SVN version of SWIG (that supports Octave), or the
octave-forge version of the database package (that has pre-generated
sources and thus doesn't depend on SWIG). I recommend the latter.
This stumped me - so then I tried to get mym to work by compiling
mym.cpp - with this I got bogged down with missing libraries and compile
errors when I tried mex etc.
You are likely to have similar problems with octave-db, since it won't
build unless you have all four database packages installed (ODBC is
almost certainly installed already, but that leaves sqlite3 and
postgres). configure should check and not build the bindings for
databases that aren't installed. I will submit a patch for this later
today.

Also there might be (will probably be) minor errors building under
MSVC, I haven't tried. (I don't have access to a Windows setup for the
time being.) Maybe someone else is willing to look at this. Building
with gcc (mingw/cygwin) would fix these.

Are the mym failures Octave related?

Thanks,
Xavier
I'd rather use the octave-db anyway because mym is not supported (and
I'd rather not have to go through the code etc.)
Thanks.
Nick
Post by Xavier Delacour
Have you tried the "database" package in octave-forge? It connects to
mysql and some other databases.
It was added recently, so you'll need to download octave-forge via SVN
to get it. Also it hasn't been tested on Windows, so Ubuntu is
probably the fastest way to get up and running. Though Windows
integration shouldn't be particularly painful, it just hasn't been
done.
http://octave-swig.sourceforge.net/octave-db.html
Xavier
Post by Nick5
I have tried all sorts of ways to connect to mysql. Has someone written a
"how to" for this?
I am trying to switch from matlab to octave - but I can't get this to work.
I used mym on matlab but I can't get it to compile for octave. I'm using XP
- though I might switch to Ubuntu if I can get octave working.
I've found a lot of people asking the same question - but no answer that
seems to work.
Thanks.
--
View this message in context: http://www.nabble.com/MySQL-from-Octave-tp16386545p16386545.html
Sent from the Octave - General mailing list archive at Nabble.com.
_______________________________________________
Help-octave mailing list
https://www.cae.wisc.edu/mailman/listinfo/help-octave
Continue reading on narkive:
Loading...