[Rails] Re: mySQL setup - I'm losing it here.
OK so now we know you're using bash, substitute "echo" for "print" in my previous mail. Rick On Dec 19, 9:52 am, Ryan Ororie wrote: > Rick wrote: > > Hello Ryan, > > >> bio4054059:depot rmorourk$ mysql -uroot depot_development > >> -bash: mysql: command not found > > > "command not found" is your shell telling you that whatever directory > > you have installed mysql in to is not on your search path. > > > If you type "print $PATH" you will see a colon separated ordered list > > of directories that are searched for executable commands. To > > temporarily extend the list just type: set PATH=MYSQLHOME:$PATH where > > MYSQLHOME is the full path to the directory containing mysql > > executable. i.e. MSQLHOME might be /usr/local/mysql/bin. You should > > then be able to execute the mysql -uroot... command. > > > Once you have success with this, you should modify your shell startup > > file to make the PATH change permanent. Depending on what shell you > > use this could be .profile, .cshrc, .tshrc, ... > > > Rick > > Thanks, here is what I tried: > > bio4054059:~ rmorourk$ print $PATH > -bash: print: command not found > bio4054059:~ rmorourk$ set PATH=/Applications/MAMP/tmp/mysql/:$PATH > bio4054059:~ rmorourk$ mysql -uroot > -bash: mysql: command not found > > Any ideas? I'm using the default terminal on MAC OS X.. > > -- > Posted viahttp://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
Ryan Ororie wrote: >> What you really want is: >> /Applications/MAMP/Library/bin/mysqladmin -u root -p root create >> depot_development >> > > Interesting, thanks... but now I am getting a problem with the password. > Observe: > > bio4054059:depot rmorourk$ /Applications/MAMP/Library/bin/mysqladmin -u > root -p root create depot_development > Enter password: > /Applications/MAMP/Library/bin/mysqladmin: Unknown command: 'root' > bio4054059:depot rmorourk$ > > When prompted for the password I typed root - which is what the password > is (at least in the database.yml file) but it gives me an unknown > command output? > > > > Rather inconsistently there should be a space between the -u and the username but there must not be a space between the -p and the password. an alternative is to use: mysqladmin --user=root --password=root create depot_development notice the double minus on the options in this form. man mysqladmin will give you information on the options and usage of the command. Norm --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
> What you really want is: > /Applications/MAMP/Library/bin/mysqladmin -u root -p root create > depot_development Interesting, thanks... but now I am getting a problem with the password. Observe: bio4054059:depot rmorourk$ /Applications/MAMP/Library/bin/mysqladmin -u root -p root create depot_development Enter password: /Applications/MAMP/Library/bin/mysqladmin: Unknown command: 'root' bio4054059:depot rmorourk$ When prompted for the password I typed root - which is what the password is (at least in the database.yml file) but it gives me an unknown command output? -- Posted via http://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
Ryan Ororie wrote: >> So based on this here is what I've done. It seems to be creating the >> database but then the rake command is saying there is no such database? >> >> bio4054059:depot rmorourk$ /Applications/MAMP/Library/bin/mysql >> mysqladmin -u root -p root create depot_development >> >> /Applications/MAMP/Library/bin/mysql Ver 14.12 Distrib 5.0.41, for >> apple-darwin8.11.1 (i686) using EditLine wrapper >> Copyright (C) 2002 MySQL AB >> This software comes with ABSOLUTELY NO WARRANTY. This is free software, >> and you are welcome to modify and redistribute it under the GPL license >> Usage: /Applications/MAMP/Library/bin/mysql [OPTIONS] [database] >> Whenever you see a message starting "Usage:" it means you did not give the correct options and the program will then go on and tell you what the options really are (in this case in a lot of detail). You in this case entered the wrong command: You apparently entered: /Applications/MAMP/Library/bin/mysql mysqladmin -u root -p root create depot_development and correctly got an error message from mysql telling you that the options were all screwed up. What you really want is: /Applications/MAMP/Library/bin/mysqladmin -u root -p root create depot_development This will probably work and give you no output message (most Unix/Linux commands are silent on success). Mysqladmin is a standalone command not a subcommand of mysql. You probably should not have to enter the full pathname but it will work. Norm --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
> set PATH=Applications/MAMP/Library/bin:$PATH > > should be > > set PATH=/Applications/MAMP/Library/bin:$PATH > > looks like it's there and even without setting the path you should be > able to do: > > /Applications/MAMP/Library/bin/mysql -u root So based on this here is what I've done. It seems to be creating the database but then the rake command is saying there is no such database? bio4054059:depot rmorourk$ /Applications/MAMP/Library/bin/mysql mysqladmin -u root -p root create depot_development /Applications/MAMP/Library/bin/mysql Ver 14.12 Distrib 5.0.41, for apple-darwin8.11.1 (i686) using EditLine wrapper Copyright (C) 2002 MySQL AB This software comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to modify and redistribute it under the GPL license Usage: /Applications/MAMP/Library/bin/mysql [OPTIONS] [database] -?, --help Display this help and exit. -I, --help Synonym for -? --auto-rehash Enable automatic rehashing. One doesn't need to use 'rehash' to get table and field completion, but startup and reconnecting may take a longer time. Disable with --disable-auto-rehash. -A, --no-auto-rehash No automatic rehashing. One has to use 'rehash' to get table and field completion. This gives a quicker start of mysql and disables rehashing on reconnect. WARNING: options deprecated; use --disable-auto-rehash instead. -B, --batch Don't use history file. Disable interactive behavior. (Enables --silent) --character-sets-dir=name Directory where character sets are. --default-character-set=name Set the default character set. -C, --compress Use compression in server/client protocol. -#, --debug[=#] This is a non-debug version. Catch this and exit -D, --database=name Database to use. --delimiter=nameDelimiter to be used. -e, --execute=name Execute command and quit. (Disables --force and history file) -E, --vertical Print the output of a query (rows) vertically. -f, --force Continue even if we get an sql error. -G, --named-commands Enable named commands. Named commands mean this program's internal commands; see mysql> help . When enabled, the named commands can be used from any line of the query, otherwise only from the first line, before an enter. Disable with --disable-named-commands. This option is disabled by default. -g, --no-named-commands Named commands are disabled. Use \* form only, or use named commands only in the beginning of a line ending with a semicolon (;) Since version 10.9 the client now starts with this option ENABLED by default! Disable with '-G'. Long format commands still work from the first line. WARNING: option deprecated; use --disable-named-commands instead. -i, --ignore-spaces Ignore space after function names. --local-infile Enable/disable LOAD DATA LOCAL INFILE. -b, --no-beep Turn off beep on error. -h, --host=name Connect to host. -H, --html Produce HTML output. -X, --xml Produce XML output --line-numbers Write line numbers for errors. -L, --skip-line-numbers Don't write line number for errors. WARNING: -L is deprecated, use long version of this option instead. -n, --unbufferedFlush buffer after each query. --column-names Write column names in results. -N, --skip-column-names Don't write column names in results. WARNING: -N is deprecated, use long version of this options instead. -O, --set-variable=name Change the value of a variable. Please note that this option is deprecated; you can set variables directly with --variable-name=value. --sigint-ignore Ignore SIGINT (CTRL-C) -o, --one-database Only update the default database. This is useful for skipping updates to other database in the update log. --pager[=name] Pager to use to display results. If you don't supply an option the default pager is taken from your ENV variable PAGER. Valid pagers are less, more, cat [> filename], etc. See interactive help (\h) also. This option does not work in batch mode. Disable with --disable-pager. This option is disabled by default. --no-pager Disa
[Rails] Re: mySQL setup - I'm losing it here.
I think set PATH=Applications/MAMP/Library/bin:$PATH should be set PATH=/Applications/MAMP/Library/bin:$PATH looks like it's there and even without setting the path you should be able to do: /Applications/MAMP/Library/bin/mysql -u root hope that helps Tim On Dec 19, 3:46 pm, Ryan Ororie wrote: > > I'd imagine that somewhere under /Applications/MAMP is a directory > > with a bunch of files with names starting with mysql. Look around, or > > run this from a prompt: > > So I found the folder (who's contents I am going to list in my output in > a second) with all the files starting with mysql. It is located here: > Applications/MAMP/Library/bin - Here is what an ls of the dir revealed: > > bio4054059:bin rmorourk$ ls > ab mysql_convert_table_format > apachectl mysql_explain_log > apr-config mysql_find_rows > apu-config mysql_fix_extensions > apxs mysql_fix_privilege_tables > autopoint mysql_install_db > checkgid mysql_secure_installation > cjpeg mysql_setpermission > comp_err mysql_tableinfo > curl mysql_tzinfo_to_sql > curl-config mysql_upgrade > dbmmanage mysql_upgrade_shell > djpeg mysql_waitpid > envsubst mysql_zap > envvars mysqlaccess > envvars-std mysqladmin > freetype-config mysqlbinlog > gettext mysqlbug > gettext.sh mysqlcheck > gettextize mysqld_multi > htdbm mysqld_safe > htdigest mysqldump > htpasswd mysqldumpslow > httpd mysqlhotcopy > httxt2dbm mysqlimport > iconv mysqlshow > idn mysqltest > innochecksum mysqltestmanager > jpegtran mysqltestmanager-pwgen > libmcrypt-config mysqltestmanagerc > libpng-config ngettext > libpng12-config perror > libtool rdjpgcom > libtoolize recode-sr-latin > logresolve replace > msgattrib resolve_stack_dump > msgcat resolveip > msgcmp rotatelogs > msgcomm sabcmd > msgconv sablot-config > msgen type1afm > msgexec wrjpgcom > msgfilter xgettext > msgfmt xml2-config > msggrep xmlcatalog > msginit xmllint > msgmerge xslt-config > msgunfmt xsltproc > msguniq yaz-asncomp > msql2mysql yaz-client > my_print_defaults yaz-config > myisam_ftdump yaz-iconv > myisamchk yaz-icu > myisamlog yaz-illclient > myisampack yaz-marcdump > mysql yaz-ztest > mysql_client_test zoomsh > mysql_config > > Assuming this was what I had been searching for, I did this: > > bio4054059:bin rmorourk$ echo $PATH > /Applications/Locomotive2/Bundles/standardRailsMar2007.locobundle/i386/bin:/Applications/Locomotive2/Bundles/standardRailsMar2007.locobundle/i386/sbin:/Users/rmorourk/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin: > bio4054059:bin rmorourk$ set PATH=Applications/MAMP/Library/bin:$PATH > bio4054059:bin rmorourk$ cd .. .. .. .. .. .. > bio4054059:Library rmorourk$ cd .. > bio4054059:MAMP rmorourk$ cd .. > bio4054059:Applications rmorourk$ cd .. > bio4054059:/ rmorourk$ cd Users/rmorourk/Sites/depot/ > bio4054059:depot rmorourk$ mysqladmin -u root create depot_devdb > -bash: mysqladmin: command not found > bio4054059:depot rmorourk$ mysql -U > -bash: mysql: command not found > bio4054059:depot rmorourk$ > > As you can see the mysql command still isn't found, any thoughts? I feel > like we are getting closer. Thanks for the help thus far!! > -- > Posted viahttp://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
> I'd imagine that somewhere under /Applications/MAMP is a directory > with a bunch of files with names starting with mysql. Look around, or > run this from a prompt: So I found the folder (who's contents I am going to list in my output in a second) with all the files starting with mysql. It is located here: Applications/MAMP/Library/bin - Here is what an ls of the dir revealed: bio4054059:bin rmorourk$ ls abmysql_convert_table_format apachectl mysql_explain_log apr-config mysql_find_rows apu-config mysql_fix_extensions apxsmysql_fix_privilege_tables autopoint mysql_install_db checkgid mysql_secure_installation cjpegmysql_setpermission comp_err mysql_tableinfo curlmysql_tzinfo_to_sql curl-config mysql_upgrade dbmmanage mysql_upgrade_shell djpegmysql_waitpid envsubst mysql_zap envvarsmysqlaccess envvars-std mysqladmin freetype-config mysqlbinlog gettextmysqlbug gettext.sh mysqlcheck gettextize mysqld_multi htdbmmysqld_safe htdigest mysqldump htpasswd mysqldumpslow httpdmysqlhotcopy httxt2dbm mysqlimport iconvmysqlshow idnmysqltest innochecksum mysqltestmanager jpegtran mysqltestmanager-pwgen libmcrypt-configmysqltestmanagerc libpng-config ngettext libpng12-config perror libtoolrdjpgcom libtoolize recode-sr-latin logresolve replace msgattrib resolve_stack_dump msgcatresolveip msgcmprotatelogs msgcommsabcmd msgconvsablot-config msgentype1afm msgexecwrjpgcom msgfilter xgettext msgfmtxml2-config msggrepxmlcatalog msginitxmllint msgmerge xslt-config msgunfmt xsltproc msguniqyaz-asncomp msql2mysql yaz-client my_print_defaultsyaz-config myisam_ftdump yaz-iconv myisamchk yaz-icu myisamlog yaz-illclient myisampack yaz-marcdump mysqlyaz-ztest mysql_client_testzoomsh mysql_config Assuming this was what I had been searching for, I did this: bio4054059:bin rmorourk$ echo $PATH /Applications/Locomotive2/Bundles/standardRailsMar2007.locobundle/i386/bin:/Applications/Locomotive2/Bundles/standardRailsMar2007.locobundle/i386/sbin:/Users/rmorourk/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin: bio4054059:bin rmorourk$ set PATH=Applications/MAMP/Library/bin:$PATH bio4054059:bin rmorourk$ cd .. .. .. .. .. .. bio4054059:Library rmorourk$ cd .. bio4054059:MAMP rmorourk$ cd .. bio4054059:Applications rmorourk$ cd .. bio4054059:/ rmorourk$ cd Users/rmorourk/Sites/depot/ bio4054059:depot rmorourk$ mysqladmin -u root create depot_devdb -bash: mysqladmin: command not found bio4054059:depot rmorourk$ mysql -U -bash: mysql: command not found bio4054059:depot rmorourk$ As you can see the mysql command still isn't found, any thoughts? I feel like we are getting closer. Thanks for the help thus far!! -- Posted via http://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
sorry thats http://www.google.com/url?sa=U&start=6&q=http://my.safaribooksonline.com/9780321606709/app01lev1sec3%3Fportal%3Doreilly&ei=yw5MSbGzHJmWsAOm9PCRDQ&sig2=jV-ITmnlJptkowoubvXwtQ&usg=AFQjCNH315zLo_wW_m0Gs3FGh9fr_sr7Rg On Dec 19, 1:19 pm, Tim McIntyre wrote: > Try > > /Applications/MAMP/Library/bin/mysql -u root > > http://my.safaribooksonline.com/9780321606709/app01lev1sec3?portal=or... > > good luck! > Tim > > On Dec 19, 11:19 am, Ryan Ororie > wrote: > > > Newbie here (who else.) I feel confident I can excel in the actual > > programming of rails apps. But all the tutorials just glaze over mySQL > > which seems to me, by far, the most problematic area for new users. > > > I have tried a ton of different things here. I know mySQL is installed > > and running in one place or another. I don't know how to tell my rails > > app with the hell to do about it. I do have the "Welcome Aboard" screen > > showing at localhost:3000 with the following details: > > > Ruby version 1.8.6 (i686-darwin8.9.1) > > RubyGems version 0.9.2 > > Rails version 1.2.3 > > Active Record version 1.15.3 > > Action Pack version 1.13.3 > > Action Web Service version 1.2.3 > > Action Mailer version 1.3.3 > > Active Support version 1.4.2 > > Application root /Users/rmorourk/Sites/depot > > Environment development > > Database adapter mysql > > > When I try to do something with the database here is what I run into. > > > bio4054059:depot rmorourk$ rake db:migrate > > (in /Users/rmorourk/Sites/depot) > > rake aborted! > > Unknown database 'depot_development' > > > The development portion of my database.yml file looks like this: > > > development: > > adapter: mysql > > database: depot_development > > username: root > > password: root > > host: localhost > > socket: /Applications/MAMP/tmp/mysql/mysql.sock > > > I added the socket line after I installed MAMP as per a tutorial... But > > when I am in the terminal and I want to do something with the database, > > like; > > > bio4054059:depot rmorourk$ mysql -uroot depot_development > > -bash: mysql: command not found > > > I get the error on the second line --- any advise? I assume this has to > > be a issue of im not telling something to look in the right somewhere, > > but I am about ready to put my fist in the wall on this thing. I would > > LOVE some advise! > > > Thanks!! > > -- > > Posted viahttp://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
sorry that's http://my.safaribooksonline.com/9780321606709/app01lev1sec3?portal=oreilly On Dec 19, 1:19 pm, Tim McIntyre wrote: > Try > > /Applications/MAMP/Library/bin/mysql -u root > > http://my.safaribooksonline.com/9780321606709/app01lev1sec3?portal=or... > > good luck! > Tim > > On Dec 19, 11:19 am, Ryan Ororie > wrote: > > > Newbie here (who else.) I feel confident I can excel in the actual > > programming of rails apps. But all the tutorials just glaze over mySQL > > which seems to me, by far, the most problematic area for new users. > > > I have tried a ton of different things here. I know mySQL is installed > > and running in one place or another. I don't know how to tell my rails > > app with the hell to do about it. I do have the "Welcome Aboard" screen > > showing at localhost:3000 with the following details: > > > Ruby version 1.8.6 (i686-darwin8.9.1) > > RubyGems version 0.9.2 > > Rails version 1.2.3 > > Active Record version 1.15.3 > > Action Pack version 1.13.3 > > Action Web Service version 1.2.3 > > Action Mailer version 1.3.3 > > Active Support version 1.4.2 > > Application root /Users/rmorourk/Sites/depot > > Environment development > > Database adapter mysql > > > When I try to do something with the database here is what I run into. > > > bio4054059:depot rmorourk$ rake db:migrate > > (in /Users/rmorourk/Sites/depot) > > rake aborted! > > Unknown database 'depot_development' > > > The development portion of my database.yml file looks like this: > > > development: > > adapter: mysql > > database: depot_development > > username: root > > password: root > > host: localhost > > socket: /Applications/MAMP/tmp/mysql/mysql.sock > > > I added the socket line after I installed MAMP as per a tutorial... But > > when I am in the terminal and I want to do something with the database, > > like; > > > bio4054059:depot rmorourk$ mysql -uroot depot_development > > -bash: mysql: command not found > > > I get the error on the second line --- any advise? I assume this has to > > be a issue of im not telling something to look in the right somewhere, > > but I am about ready to put my fist in the wall on this thing. I would > > LOVE some advise! > > > Thanks!! > > -- > > Posted viahttp://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
Try /Applications/MAMP/Library/bin/mysql -u root http://my.safaribooksonline.com/9780321606709/app01lev1sec3?portal=oreilly good luck! Tim On Dec 19, 11:19 am, Ryan Ororie wrote: > Newbie here (who else.) I feel confident I can excel in the actual > programming of rails apps. But all the tutorials just glaze over mySQL > which seems to me, by far, the most problematic area for new users. > > I have tried a ton of different things here. I know mySQL is installed > and running in one place or another. I don't know how to tell my rails > app with the hell to do about it. I do have the "Welcome Aboard" screen > showing at localhost:3000 with the following details: > > Ruby version 1.8.6 (i686-darwin8.9.1) > RubyGems version 0.9.2 > Rails version 1.2.3 > Active Record version 1.15.3 > Action Pack version 1.13.3 > Action Web Service version 1.2.3 > Action Mailer version 1.3.3 > Active Support version 1.4.2 > Application root /Users/rmorourk/Sites/depot > Environment development > Database adapter mysql > > When I try to do something with the database here is what I run into. > > bio4054059:depot rmorourk$ rake db:migrate > (in /Users/rmorourk/Sites/depot) > rake aborted! > Unknown database 'depot_development' > > The development portion of my database.yml file looks like this: > > development: > adapter: mysql > database: depot_development > username: root > password: root > host: localhost > socket: /Applications/MAMP/tmp/mysql/mysql.sock > > I added the socket line after I installed MAMP as per a tutorial... But > when I am in the terminal and I want to do something with the database, > like; > > bio4054059:depot rmorourk$ mysql -uroot depot_development > -bash: mysql: command not found > > I get the error on the second line --- any advise? I assume this has to > be a issue of im not telling something to look in the right somewhere, > but I am about ready to put my fist in the wall on this thing. I would > LOVE some advise! > > Thanks!! > -- > Posted viahttp://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
On Fri, Dec 19, 2008 at 12:02 PM, Ryan Ororie wrote: > First, how do I add it to my PATH? Second, I used this to install mySQL: > http://www.mamp.info/en/index.php > > Not sure if that was necessary/proper. Definitely not necessary, but whatever -- let's assume it worked for the moment :-) > The install folder for MAMP has this: > /Applications/MAMP/tmp/mysql/ > > Which holds two files mysql.pid and mysqp.sock - am I correct in > assuming that those are the executables I need to set my path too? No. The first contains the process id of the mysql server, and the other is the socket used to communicate with it. I'd imagine that somewhere under /Applications/MAMP is a directory with a bunch of files with names starting with mysql. Look around, or run this from a prompt: find /Application/MAMP -type f -name 'mysql*' -print > Symlinks? Um, I'd recommend doing a little reading up on general *nix/shell use. ("symlinks" is short for "symbolic links" -- a way to have a file referenced from a different directory than it's really located in.) But we can skip that for now; you just need to find what to add to your PATH. And Rick already explained that. Oh, yeah, but it's `echo $PATH`, not `print`. HTH, -- Hassan Schroeder hassan.schroe...@gmail.com --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
How did you install mysql? If you used port then its mysql5 not mysql which is the command to open the mysql client... If you are trying to install mysql using anything other than macports.. dont't... I recommend that you go to macports.org site and download the latest version... On Dec 19, 12:02 pm, Ryan Ororie wrote: > > Which simply means MySQL isn't in your PATH. You need to find > > where the MySQL executables are installed and add that directory > > to your path. Or create symlinks to, say, /usr/local/bin. > > First, how do I add it to my PATH? Second, I used this to install > mySQL:http://www.mamp.info/en/index.php > > Not sure if that was necessary/proper. > > The install folder for MAMP has this: > /Applications/MAMP/tmp/mysql/ > > Which holds two files mysql.pid and mysqp.sock - am I correct in > assuming that those are the executables I need to set my path too? > > Symlinks? > > Thanks for the help thus far! > -- > Posted viahttp://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
> Which simply means MySQL isn't in your PATH. You need to find > where the MySQL executables are installed and add that directory > to your path. Or create symlinks to, say, /usr/local/bin. First, how do I add it to my PATH? Second, I used this to install mySQL: http://www.mamp.info/en/index.php Not sure if that was necessary/proper. The install folder for MAMP has this: /Applications/MAMP/tmp/mysql/ Which holds two files mysql.pid and mysqp.sock - am I correct in assuming that those are the executables I need to set my path too? Symlinks? Thanks for the help thus far! -- Posted via http://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
Rick wrote: > Hello Ryan, > >> � � bio4054059:depot rmorourk$ mysql -uroot depot_development >> � � -bash: mysql: command not found > > "command not found" is your shell telling you that whatever directory > you have installed mysql in to is not on your search path. > > If you type "print $PATH" you will see a colon separated ordered list > of directories that are searched for executable commands. To > temporarily extend the list just type: set PATH=MYSQLHOME:$PATH where > MYSQLHOME is the full path to the directory containing mysql > executable. i.e. MSQLHOME might be /usr/local/mysql/bin. You should > then be able to execute the mysql -uroot... command. > > Once you have success with this, you should modify your shell startup > file to make the PATH change permanent. Depending on what shell you > use this could be .profile, .cshrc, .tshrc, ... > > Rick Thanks, here is what I tried: bio4054059:~ rmorourk$ print $PATH -bash: print: command not found bio4054059:~ rmorourk$ set PATH=/Applications/MAMP/tmp/mysql/:$PATH bio4054059:~ rmorourk$ mysql -uroot -bash: mysql: command not found Any ideas? I'm using the default terminal on MAC OS X.. -- Posted via http://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
On Fri, Dec 19, 2008 at 11:19 AM, Ryan Ororie wrote: > I have tried a ton of different things here. I know mySQL is installed > and running in one place or another. I don't know how to tell my rails > app with the hell to do about it. I > When I try to do something with the database here is what I run into. > >bio4054059:depot rmorourk$ rake db:migrate >(in /Users/rmorourk/Sites/depot) >rake aborted! >Unknown database 'depot_development' So you haven't created that database yet. No mystery there. :-) > when I am in the terminal and I want to do something with the database, > like; > >bio4054059:depot rmorourk$ mysql -uroot depot_development >-bash: mysql: command not found Which simply means MySQL isn't in your PATH. You need to find where the MySQL executables are installed and add that directory to your path. Or create symlinks to, say, /usr/local/bin. This is just basic *nix stuff. HTH, -- Hassan Schroeder hassan.schroe...@gmail.com --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
Hello Ryan, > bio4054059:depot rmorourk$ mysql -uroot depot_development > -bash: mysql: command not found "command not found" is your shell telling you that whatever directory you have installed mysql in to is not on your search path. If you type "print $PATH" you will see a colon separated ordered list of directories that are searched for executable commands. To temporarily extend the list just type: set PATH=MYSQLHOME:$PATH where MYSQLHOME is the full path to the directory containing mysql executable. i.e. MSQLHOME might be /usr/local/mysql/bin. You should then be able to execute the mysql -uroot... command. Once you have success with this, you should modify your shell startup file to make the PATH change permanent. Depending on what shell you use this could be .profile, .cshrc, .tshrc, ... Rick > I get the error on the second line --- any advise? I assume this has to > be a issue of im not telling something to look in the right somewhere, > but I am about ready to put my fist in the wall on this thing. I would > LOVE some advise! > > Thanks!! > -- > Posted viahttp://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---
[Rails] Re: mySQL setup - I'm losing it here.
Hello Ryan, Make sure you have only one mysql in ur machine and there is database with name 'depot_development' and try again. Thanks, Sadeesh. On Dec 20, 12:19 am, Ryan Ororie wrote: > Newbie here (who else.) I feel confident I can excel in the actual > programming of rails apps. But all the tutorials just glaze over mySQL > which seems to me, by far, the most problematic area for new users. > > I have tried a ton of different things here. I know mySQL is installed > and running in one place or another. I don't know how to tell my rails > app with the hell to do about it. I do have the "Welcome Aboard" screen > showing at localhost:3000 with the following details: > > Ruby version1.8.6 (i686-darwin8.9.1) > RubyGems version0.9.2 > Rails version1.2.3 > Active Record version1.15.3 > Action Pack version1.13.3 > Action Web Service version1.2.3 > Action Mailer version1.3.3 > Active Support version1.4.2 > Application root/Users/rmorourk/Sites/depot > Environmentdevelopment > Database adaptermysql > > When I try to do something with the database here is what I run into. > > bio4054059:depot rmorourk$ rake db:migrate > (in /Users/rmorourk/Sites/depot) > rake aborted! > Unknown database 'depot_development' > > The development portion of my database.yml file looks like this: > > development: > adapter: mysql > database: depot_development > username: root > password: root > host: localhost > socket: /Applications/MAMP/tmp/mysql/mysql.sock > > I added the socket line after I installed MAMP as per a tutorial... But > when I am in the terminal and I want to do something with the database, > like; > > bio4054059:depot rmorourk$ mysql -uroot depot_development > -bash: mysql: command not found > > I get the error on the second line --- any advise? I assume this has to > be a issue of im not telling something to look in the right somewhere, > but I am about ready to put my fist in the wall on this thing. I would > LOVE some advise! > > Thanks!! > -- > Posted viahttp://www.ruby-forum.com/. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~--~~~~--~~--~--~---