MySQL getting started

hypocampers

Registered
This is a learning excercise I have installed MySQL (as per Marc Liyange notes) on my machines running 10.2.1.

Now I have installed it, what the best way to start tinkering with it, i.e. get data into a database, search the database and get data out of it.


What I need is some basic tools or ascripts to use via the terminal, that work, to accomplish the above to get a feel of what going on, from there I can move upto PHP etc.

Many thanks in advance
 
Are there any good Perl solutions for administering a remote MySQL database? (Setting one up, entering data, etc...)
 
Don't forget about: www.mysql.com can't think of a better place for reference. But devshed is good for tutorials and stuff. For database specific questions they have good forums(not quite as pretty as this forum though). Looking into something called Jane Builder as a front end for your database. I know you can get it here: www.apple.com/downloads
 
For what it's worth, you might want to take a look at PostgreSQL, too, and see which database works best for you. Personally, I think MySQL is horribly crippled since it can't even perform nested queries.
Code:
SELECT name
FROM table
WHERE name NOT IN (SELECT name FROM otherTable)

Of course, PostgreSQL has a rather brain dead syntax error reporter that makes debugging a little tricky. Overall, I personally think it's the better choice, unless you're trying to do something that depends on MySQL for it to work correctly.
 
FYI - the MacWorld mag I rec yesterday has an article on installing and using MySQL and also on using Golive with MySQL. Prob not worth buying the whole issue for those article - but you might peruse them when they come online at MacWorld site.
 
Again many thanks for more links and detail. I will definately look at PostGreSQL as soon as this small project is under way.

Once I've got a good idea where I can go with this, I want to take a look at writting a query through athe browser, which will correlate data from ORACLE and other databases, store those queries and resturned data in a query database for further examintation. This will be primarily used in the Oil & Gas arena, but Biotechnology is the desired end result.

I have setup PHP and its running just fine with MySQL, have setup test databases (artwork and text data on the painters) and it looks fine for this kind of work.

One question though, i am a UNIX man and quite like to be able to run in command mode behind the scenes, I issue the following and get this:

> mysql

dyld: ./mysql Undefined symbols:
./mysql undefined reference to _BC expected to be defined in /usr/lib/libSystem.B.dylib
./mysql undefined reference to _PC expected to be defined in /usr/lib/libSystem.B.dylib
./mysql undefined reference to _UP expected to be defined in /usr/lib/libSystem.B.dylib
Trace/BPT trap

I have had a quick look but there doesn't seem to be a resolution to it, which means I cannot run the text interface.

I have tar'ed the database, removed MySQL, re-installed MySQL, un-tarred the database and the PHP interface work just fine, if I issue "mysql" I get the above problem still.

Anybody run into this and git a resolution.

Thanks again

Rob
 
That's usually what happens when you try to run binaries from 10.1 on a 10.2 system. The quick fix is to find the absolute newest version of the MySQL package and install that. The version I installed didn't have that problem, but damned if I can remember where I got it...
 
Thanks for the pointer, I'll take a look.

I am running 3.23.51 and using Mark Lyiange's (spelling close enough I hope) distribution.

Cheers
 
davidbrit2

Yup you were right, I had downloaded a non-jaguar version of mysql 3.23.51.
Strange that the version worked just fine but not from the command prompt, normally its the other way around.

Anyway many thanks, I'll fax you some Welsh Beer, believe it or not its called "Brains", something which I lack...probably from drinking the stuff.
 
Heh. That's good that it's working okay now. A good DBMS just isn't any fun without a low level command interpreter. :)
 
Back
Top