View Full Version : MySQL Issues.
Colin Campbell
07-20-2003, 10:37 PM
How am I supposed to write a MySQL script? I'm on mac, and have it installed, but how do I actually write the script? (I know what I want to write, just how do I put it in?) Windows input welcome.
freddycodes
07-20-2003, 11:27 PM
MySQL script? There isn't reall such a thing. MySQL is a RDBMS(Relationtional Database Management System), albiet a shitty one. You normally write scripts in Perl ,PHP, Java, etc... to access a database.
Colin Campbell
07-20-2003, 11:29 PM
but how do I create one in the first place?
freddycodes
07-21-2003, 02:19 PM
With a text editor.
Try starting here, it goes through install on windows, but afterwards starts with how to write basic scripts.
http://www.sitepoint.com/article/525
Colin Campbell
07-21-2003, 11:49 PM
ugh, I'm so confused. I have all the stuff installed (did that before) but I can't find the bin directory of the mysql place. Is there a certain thing I have to type?
freddycodes
07-21-2003, 11:50 PM
I don't work on Macs.
Colin Campbell
07-22-2003, 12:00 AM
What do you do on Windows? I'm trying to figure out how to change the root password right now, I've figured out how to get the bin...
freddycodes
07-22-2003, 12:04 AM
mysqladmin -u root password <password>
Where <password> is the new password you want root to have.
Colin Campbell
07-22-2003, 12:06 AM
where are you typing that? Into the text editor? Sorry, I'm just so lost...
freddycodes
07-22-2003, 12:08 AM
Your problem is you are trying to jump to far into things without knowing the basics. Like how to run system commands, on windows you use a dos prompt, I am not sure how you do it on a Mac. Have you installed PHP? Can you browse http://localhost in a browser and see your web server?
freddycodes
07-22-2003, 12:10 AM
Did you happen to read the manual at all?
http://www.mysql.com/documentation/mysql/bychapter/manual_Installing.html#Mac_OS_X_installation
Colin Campbell
07-22-2003, 11:20 AM
Still no luck. I looked through most of the stuff there and it won't work... I keep getting this:
________________
ERROR 1064: You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'code here' at line 1
________________
know anything about that?
whats the sql your trying to run against your database?
freddycodes
07-22-2003, 01:07 PM
I hate to say this colin, and I am not trying to be rude, but your error messages are way to vague, and your ability to relate what it is you are trying in terms we can understand needs some help. Thats why I mentioned you may want to start with something simple, like running system commands to list directories and getting used to the command line on OSX. Then move into something a little more adevanced like managing a MySQL database.
The reason I asked about PHP earlier, if you can get the web server running php, you can put software like phpMyAdmin on the web server. This would give you a web interface for managing the databases, might be easier than the command line at this point.
Colin Campbell
07-22-2003, 10:49 PM
Yeah, I know I have PHP up and running just fine. Maybe I'll try that...
vaska
07-23-2003, 10:03 AM
colin...if you see me on AIM drop me a line...i might be able to help...
AIM :: vvvaska
Colin Campbell
07-23-2003, 12:32 PM
Ok, so I figured out what was wrong with the install database stuff, but can anyone tell me how to log in?
vaska
07-23-2003, 01:11 PM
mac os x?
use the terminal...
vaska
Colin Campbell
07-23-2003, 01:41 PM
I know that :p
vaska
07-23-2003, 01:57 PM
goto
http://www.macrumors.com
goto the forum > the help section
and search on "terminal" and "php"
you'll find all you need to make it work...
vaska
|
vBulletin® v3.8.4, Copyright ©2000-2009, Jelsoft Enterprises Ltd.