Sorry, but this is really NOT as easy as the tutorials/books make out. I''m really struggling at the first hurdle here. And while I''m not a programmer by design I do know my way around most stuff. And if I can''t get this to work I suspect more people will have the same issues. There seems to be too many variables to address. I have winXP, I have ruby and rails all working OK and have done the first "hello world" stuff. Now when I try to connnect to mySQL I get "#28000Access denied for user ''root''@''localhost'' (using password: NO)". I''ve tried everything, resetting, new password, restarting server, mySQL, re-install of mySQL. All to know avail. Having bought the book and gone to all this trouble to get something working I''m struggling to see what the point is. I could have connected to a database and done this with php pretty quickly compared to the two unbillable days so far. Please convert me back to wanting to use rails...someone! -- Posted via http://www.ruby-forum.com/.
Andrew VanSpronsen
2006-Mar-02 18:52 UTC
[Rails] can''t get rails to connect to mySQL - HELP!!!!!!!!!
Hello, Did you configure your database.yml file with the appropriate credentials for your MySQL server? Andrew On 3/2/06, john <thestudio@reservoir.biz> wrote:> > Sorry, but this is really NOT as easy as the tutorials/books make out. > I''m really struggling at the first hurdle here. And while I''m not a > programmer by design I do know my way around most stuff. And if I can''t > get this to work I suspect more people will have the same issues. There > seems to be too many variables to address. > I have winXP, I have ruby and rails all working OK and have done the > first "hello world" stuff. Now when I try to connnect to mySQL I get > "#28000Access denied for user ''root''@''localhost'' (using password: NO)". > I''ve tried everything, resetting, new password, restarting server, > mySQL, re-install of mySQL. All to know avail. > Having bought the book and gone to all this trouble to get something > working I''m struggling to see what the point is. I could have connected > to a database and done this with php pretty quickly compared to the two > unbillable days so far. > Please convert me back to wanting to use rails...someone! > > -- > Posted via http://www.ruby-forum.com/. > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >-- ---------------------------------------------------- Gmail - Hits the spot! :-) GPG Key ID: 1024D/F18A34B9 2005-08-27 Andrew VanSpronsen (E-mail key) < avanspronsen@gmail.com> -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060302/c7288865/attachment.html
Kevin Elhart
2006-Mar-02 18:59 UTC
[Rails] Re: can''t get rails to connect to mySQL - HELP!!!!!!!!!
john wrote:> "#28000Access denied for user ''root''@''localhost'' (using password: NO)".I recall having issues connect to mySql with ''root''...I didn''t bother to chase the problem any further, I''ve found the following works well: On the mysql console, create your database, then do:> use <database> > grant all on <database>.* TO ''foo''@''localhost'' using ''foopass'';Then update your database.yml so it is configured to access your <database> using foo and foopass as the user and password. You should probably restart your server (apache, lightttpd, or whichever) after you do these changtes to ensure it picks them up. -- Posted via http://www.ruby-forum.com/.
Derrick Spell
2006-Mar-02 19:06 UTC
[Rails] can''t get rails to connect to mySQL - HELP!!!!!!!!!
On 3/2/06, john < thestudio@reservoir.biz> wrote: Sorry, but this is really NOT as easy as the tutorials/books make out. I''m really struggling at the first hurdle here. And while I''m not a programmer by design I do know my way around most stuff. And if I can''t get this to work I suspect more people will have the same issues. There seems to be too many variables to address. I have winXP, I have ruby and rails all working OK and have done the first "hello world" stuff. Now when I try to connnect to mySQL I get "#28000Access denied for user ''root''@''localhost'' (using password: NO)". I''ve tried everything, resetting, new password, restarting server, mySQL, re-install of mySQL. All to know avail. Having bought the book and gone to all this trouble to get something working I''m struggling to see what the point is. I could have connected to a database and done this with php pretty quickly compared to the two unbillable days so far. Please convert me back to wanting to use rails...someone! You have to setup your database.yml file with the proper username and password to your database (just like they told you to do in the tutorials ;) ). This is of course assuming that you have actually set up MySQL correctly. Hm, winXP... that may be the problem right there. *sigh* ;) -Derrick Spell -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060302/34773369/attachment.html
john
2006-Mar-02 19:58 UTC
[Rails] Re: can''t get rails to connect to mySQL - HELP!!!!!!!!!
thanks for the prompt replies. Sadly, still no joy. Tried the grant all but this did not help either. I have set up the yml file as per the tutorials. Sadly, I have gone through the tutorial from agile web development line by line and still not been able to achieve the "agility" promised. my yml file has this: adapter: mysql database: depot_test username: password:foo socket: /path/to/your/mysql.sock I can log into mySQL from the command line so I figure that is set up OK. Is win XP the issue. I have a mac - I could upgrade to Tiger and work on that if that is a better environment. I would really like to make this work so I''m willing to try any suggestions. -- Posted via http://www.ruby-forum.com/.
Andrew VanSpronsen
2006-Mar-02 20:06 UTC
[Rails] Re: can''t get rails to connect to mySQL - HELP!!!!!!!!!
My config file looks like this: adapter: mysql database: eventweb host: localhost username: root password: mypassword socket: /path/to/your/mysql.sock Andrew On 3/2/06, john <thestudio@reservoir.biz> wrote:> > thanks for the prompt replies. > Sadly, still no joy. > > Tried the grant all but this did not help either. > > I have set up the yml file as per the tutorials. Sadly, I have gone > through the tutorial from agile web development line by line and still > not been able to achieve the "agility" promised. > > my yml file has this: > adapter: mysql > database: depot_test > username: > password:foo > socket: /path/to/your/mysql.sock > > I can log into mySQL from the command line so I figure that is set up > OK. > Is win XP the issue. I have a mac - I could upgrade to Tiger and work on > that if that is a better environment. > > I would really like to make this work so I''m willing to try any > suggestions. > > -- > Posted via http://www.ruby-forum.com/. > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >-- ---------------------------------------------------- Gmail - Hits the spot! :-) GPG Key ID: 1024D/F18A34B9 2005-08-27 Andrew VanSpronsen (E-mail key) < avanspronsen@gmail.com> -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060302/293e8d38/attachment.html
Lurlay, Patrick
2006-Mar-02 21:02 UTC
[Rails] Re: can''t get rails to connect to mySQL - HELP!!!!!!!!!
This insturction assumes that you are using mysql 5.x 1. login to mysql as admin user 2. use myslq; 3. create database depot_test; 4. ---create new user for your db insert into user(Host,User,Password, insert_priv, update_priv, create_priv, select_priv, delete_priv, drop_priv, ssl_cipher, x509_issuer, x509_subject) values("localhost","jdoe",Password(''jdoe''), "Y", "Y", "Y", "Y", "Y", "Y", "Y" ,"Y", "Y"); 5. flush privileges; 6. grant select,create,update,drop,delete,insert on depot_test.* to jdoe@localhost identified by ''jdoe''; 7. use depot_test; 8. go ahead and create your tables-----) 9 configure your database.yml to look like below: adapter: mysql database: depot_test username:jdoe password:jdoe #socket: /path/to/your/mysql.sock Cheers Patrick -----Original Message----- From: rails-request@lists.rubyonrails.org [mailto:rails-request@lists.rubyonrails.org] Sent: Thursday, March 02, 2006 12:36 PM To: rails@lists.rubyonrails.org Subject: Rails Digest, Vol 18, Issue 43 Send Rails mailing list submissions to rails@lists.rubyonrails.org To subscribe or unsubscribe via the World Wide Web, visit http://lists.rubyonrails.org/mailman/listinfo/rails or, via email, send a message with subject or body ''help'' to rails-request@lists.rubyonrails.org You can reach the person managing the list at rails-owner@lists.rubyonrails.org When replying, please edit your Subject line so it is more specific than "Re: Contents of Rails digest..." Today''s Topics: 1. Re: Re: can''t get rails to connect to mySQL - HELP!!!!!!!!! (Andrew VanSpronsen) 2. Re: @session[] or session[] (Marcel Molina Jr.) 3. Re: Getting Acts_as_Paranoid to work with validates_uniqueness_of (Berin Loritsch) 4. merge with symbol problem (Abbath) 5. Re: Modifying "Find" to always add a condition? (Mathias Stjernstr?m) 6. url_for_file_column not returning correct path (Nithin Reddy) 7. Re: Use ActiveRecord outside of Rails to upload to database? (Chris Jennings) 8. Re: merge with symbol problem (Nithin Reddy) 9. Speaking of sessions (David Newberger) 10. Re: Re: The no-framework PHP MVC framework (Greg Donald) 11. Re: @session[] or session[] (Justin Blake) ---------------------------------------------------------------------- Message: 1 Date: Thu, 2 Mar 2006 15:06:03 -0500 From: "Andrew VanSpronsen" <avanspronsen@gmail.com> Subject: Re: [Rails] Re: can''t get rails to connect to mySQL - HELP!!!!!!!!! To: rails@lists.rubyonrails.org Message-ID: <da60f81b0603021206t332a285fvd49945588a77379f@mail.gmail.com> Content-Type: text/plain; charset="iso-8859-1" My config file looks like this: adapter: mysql database: eventweb host: localhost username: root password: mypassword socket: /path/to/your/mysql.sock Andrew On 3/2/06, john <thestudio@reservoir.biz> wrote:> > thanks for the prompt replies. > Sadly, still no joy. > > Tried the grant all but this did not help either. > > I have set up the yml file as per the tutorials. Sadly, I have gone > through the tutorial from agile web development line by line and still > not been able to achieve the "agility" promised. > > my yml file has this: > adapter: mysql > database: depot_test > username: > password:foo > socket: /path/to/your/mysql.sock > > I can log into mySQL from the command line so I figure that is set up > OK. > Is win XP the issue. I have a mac - I could upgrade to Tiger and work > on that if that is a better environment. > > I would really like to make this work so I''m willing to try any > suggestions. > > -- > Posted via http://www.ruby-forum.com/. > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >-- ---------------------------------------------------- Gmail - Hits the spot! :-) GPG Key ID: 1024D/F18A34B9 2005-08-27 Andrew VanSpronsen (E-mail key) < avanspronsen@gmail.com> -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060302/293e8d38/attachment-0001.html ------------------------------ Message: 2 Date: Thu, 2 Mar 2006 14:22:35 -0600 From: "Marcel Molina Jr." <marcel@vernix.org> Subject: Re: [Rails] @session[] or session[] To: rails@lists.rubyonrails.org Message-ID: <20060302202235.GY27797@chicago.vernix.org> Content-Type: text/plain; charset=us-ascii On Thu, Mar 02, 2006 at 03:01:49PM -0500, Justin Blake wrote:> Which is more appropriate? @session[] or session[]? Both seem to work. > Is there a difference between which should be used in the controller > vs. the view?session should be used exclusively. Same goes for params, controller, etc. marcel -- Marcel Molina Jr. <marcel@vernix.org> ------------------------------ Message: 3 Date: Thu, 02 Mar 2006 15:14:58 -0500 From: Berin Loritsch <bloritsch@d-haven.org> Subject: Re: [Rails] Getting Acts_as_Paranoid to work with validates_uniqueness_of To: rails@lists.rubyonrails.org Message-ID: <44075242.4050108@d-haven.org> Content-Type: text/plain; charset=UTF-8; format=flowed Harvey Bernstein wrote:> Hello > I''ve been using Acts_as_Parnoid for a while and it has been working well > but I am now having a slight issue with it. I have a company table were > I would like to use validates_uniqueness_of :company_name. This > validation works if a company exists in the database and has not been > deleted. However, I also would like the validates_uniqueness_of to > work if a company has previously been deleted and has been flagged in > the deleted_at column. Currently, if a company has been deleted, it is > possible to create another company with the same name. I would like to > bring up a validation message to inform the user. Is there an easy way > to accomplish this? > > Any help would be greatly appreciated. >Looking at the plugin code, you would have to specify the option :with_deleted => true to find companies that have been deleted. The full list of options for find with this plugin is: [:conditions, :include, :joins, :limit, :offset, :order, :select, :readonly, :group, :from, :with_deleted] Not sure how validates_uniqueness_of works. I''ll look into that next. ------------------------------ Message: 4 Date: Thu, 02 Mar 2006 21:14:19 +0100 From: Abbath <abbath@invitel.hu> Subject: [Rails] merge with symbol problem To: rails@lists.rubyonrails.org Message-ID: <1956775800.20060302211419@invitel.hu> Content-Type: text/plain; charset=us-ascii Hi, It''s a little bit annoying to me, I can''t understand the following: If I merge a value to the params hash with: params => params.merge :value => new_value the params[:value] doesn''t change, but if I use string instead of a symbol like: params => params.merge "value" => new_value it works. Somebody plz tell me why... Abbath ------------------------------ Message: 5 Date: Thu, 2 Mar 2006 21:15:51 +0100 From: Mathias Stjernstr?m <mathias@globalinn.se> Subject: Re: [Rails] Modifying "Find" to always add a condition? To: gedwards1@eyetools.com, rails@lists.rubyonrails.org Message-ID: <D378A679-0B7E-4CD5-8BA4-277214471012@globalinn.se> Content-Type: text/plain; charset=ISO-8859-1; delsp=yes; format=flowed Hi Greg! I have been working on a plugin for a couple of days that i think do what you want. I call it Acts as restricted. Its one of those Acts_as plugins, DUH. You simply add acts_as_restricted to your model and then tree columns to the model table owner_id, group_id and restricted owner_id is the owner of the object, group_id is the group the object belongs to and restricted is a integer that handles the current permissions for the object. The permission can be: OWNER_READ, OWNER_WRITE, OWNER_DELETE GROUP_READ, GROUP_WRITE, GROUP_DELETE WORLD_READ, WORLD_WRITE, WORLD_DELETE The plugin then overrides the find/destroy/save/count methods of that object to check if the permissions is correct for the current user. I have only been using rails for a couple of weeks so a cannot guarantee that it''s fail-safe, but it works pretty good so far ;-) I am waiting for ruby-forge approval for my project and then i put it out in public. Cheers! Mathias Stjernstrom On Mar 2, 2006, at 11:24 AM, Greg Edwards wrote:> I''d like to always add a condition to any version of "find" (e.g. > Thing.find(), Thing.find_by_name(), Thing.find_by_whatever) so that in > addition to whatever conditions are set, an additional condition is > set > :conditions=>"user_id=#{current_user.id}" > > I''d like to make sure that a user only sees/edits/creates entries > in the > database that have the user_id field set to their id. I could wrap > all of my > controller functions (create/new/show/edit/list) with > begin > #note having to add to the ":conditions" field > @thing = Thing.find(params[:id], > :conditions=>"user_id=#{current_user.id}") > rescue > render :text=>"I''m sorry, you do not have access to that > record." > end > ...but clearly that is immensely un-DRY. AND, it removes the > ability to use > the helpful Thing.find_by_name/etc functions. > > The goal is to make all versions of "find" work. > > Is it possible to change one function in the model and make it work? > > Thanks, > -Greg > > Greg Edwards > CTO, Eyetools Inc. > (916) 792 4538 > > > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails-- Mathias Stjernstr?m mathias@globalinn.se Direktnr: 08 - 525 09 112 V?xel: 020 - 140 00 60 Fax: 020 - 140 00 61 ------------------------------ Message: 6 Date: Thu, 2 Mar 2006 12:19:48 -0800 From: "Nithin Reddy" <jashugan@gmail.com> Subject: [Rails] url_for_file_column not returning correct path To: rails@lists.rubyonrails.org Message-ID: <994e7e3c0603021219p24ce5940p7647a27576726153@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1 I added this test towards the end of the included file_column_helper_test.rb that shipped with the file_column plugin: def test_url_for_file_column_different_root_path Entry.file_column :image, :root_path => File.join(RAILS_ROOT, "public/files") e = Entry.new(:image => upload(f("skanthak.png"))) assert_match %r{/public/files/entry/image}, e.image_options[:store_dir] assert e.save assert_match %r{files/entry/image}, url_for_file_column(e, "image") end the last assert_match did not pass... 1) Failure: test_url_for_file_column_different_root_path(UrlForFileColumnTest) [file_column_helper_test.rb:59]: <"/entry/image/1/skanthak.png"> expected to be =~ </files\/entry\/image/>. The file is correctly stored in the :root_path specified. It''s as if url_for_file_column doesn''t take it into account. Has anyone else experienced this problem? ------------------------------ Message: 7 Date: Thu, 2 Mar 2006 21:20:54 +0100 From: Chris Jennings <cpher@spatialbytes.com> Subject: [Rails] Re: Use ActiveRecord outside of Rails to upload to database? To: rails@lists.rubyonrails.org Message-ID: <cffe924c9e86ce2334eedc120cb7765d@ruby-forum.com> Content-Type: text/plain; charset=utf-8 Mikkel, Thanks. Shortly after I posted, I found a wiki page describing it. Thanks for the reminder to check that wiki more often. -- Posted via http://www.ruby-forum.com/. ------------------------------ Message: 8 Date: Thu, 2 Mar 2006 12:28:09 -0800 From: "Nithin Reddy" <jashugan@gmail.com> Subject: Re: [Rails] merge with symbol problem To: Abbath <abbath@invitel.hu>, rails@lists.rubyonrails.org Message-ID: <994e7e3c0603021228q437903f9s88f85f496a88f40c@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1 I believe that :value and "value" are complety different keys. One is a string, the other is a symbol. On 3/2/06, Abbath <abbath@invitel.hu> wrote:> Hi, > > It''s a little bit annoying to me, I can''t understand the following: > > If I merge a value to the params hash with: > > params => params.merge :value => new_value > > the params[:value] doesn''t change, but if I use string instead of a > symbol like: > > params => params.merge "value" => new_value > > it works. > > Somebody plz tell me why... > > Abbath > > > > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >------------------------------ Message: 9 Date: Thu, 02 Mar 2006 14:28:21 -0600 From: David Newberger <me@davidnewberger.com> Subject: [Rails] Speaking of sessions To: Rails@lists.rubyonrails.org Message-ID: <44075565.10008@davidnewberger.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Hi All, I am trying to figure out some models and controller for a time tracking system. More specifically I am trying to figure out the best way to track how long a user was logged in for a given day week or month. I was thinking from a database standpoint of having a created_ and and updated_at in a session table and then I would find out the hours and minutes that a user was logged in for that session. Then I would store that information with the day it was. I would then create a class that looks for a month, week, or day and calculates the total for each and outputs it in a report. The reason I am coming to this list is because I would to get your thoughts on this and any ideas as to weather it has been done before and how. -- David Newberger Daddy, Developer, Geek, Blogger 651.271.9045 me@davidnewberger.com http://www.davidnewberger.com ------------------------------ Message: 10 Date: Thu, 2 Mar 2006 14:32:06 -0600 From: "Greg Donald" <gdonald@gmail.com> Subject: Re: [Rails] Re: The no-framework PHP MVC framework To: rails@lists.rubyonrails.org Message-ID: <15e66e4e0603021232x30127e3etfb1b23a08858401@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1 On 3/2/06, Joe <joe@yahoo.com> wrote:> Oh I know who Rasmus is and without him PHP would be much worse off.If by ''much worse off'' you mean ''not invented'' then yes. -- Greg Donald Zend Certified Engineer MySQL Core Certification http://destiney.com/ ------------------------------ Message: 11 Date: Thu, 2 Mar 2006 15:35:15 -0500 From: "Justin Blake" <jblaix@gmail.com> Subject: Re: [Rails] @session[] or session[] To: rails@lists.rubyonrails.org Message-ID: <21e25d8d0603021235s59dc3785xbdcb9bd1ee71ed1c@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1 On 3/2/06, Marcel Molina Jr. <marcel@vernix.org> wrote:> session should be used exclusively. Same goes for params, controller, etc.Thanks! But any explanation as to why @session works? ------------------------------ _______________________________________________ Rails mailing list Rails@lists.rubyonrails.org http://lists.rubyonrails.org/mailman/listinfo/rails End of Rails Digest, Vol 18, Issue 43 *************************************
Lurlay, Patrick
2006-Mar-02 21:06 UTC
[Rails] Re: can''t get rails to connect to mySQL - HELP!!!!!!!!!
Andrew, the instruction below should do the trick for you. This insturction assumes that you are using mysql 5.x 1. login to mysql as admin user 2. use myslq; 3. create database depot_test; 4. ---create new user for your db insert into user(Host,User,Password, insert_priv, update_priv, create_priv, select_priv, delete_priv, drop_priv, ssl_cipher, x509_issuer, x509_subject) values("localhost","jdoe",Password(''jdoe''), "Y", "Y", "Y", "Y", "Y", "Y", "Y" ,"Y", "Y"); 5. flush privileges; 6. grant select,create,update,drop,delete,insert on depot_test.* to jdoe@localhost identified by ''jdoe''; 7. use depot_test; 8. go ahead and create your tables-----) 9 configure your database.yml to look like below: adapter: mysql database: depot_test username:jdoe password:jdoe #socket: /path/to/your/mysql.sock Cheers Patrick
Derrick Spell
2006-Mar-02 21:33 UTC
[Rails] Re: can''t get rails to connect to mySQL - HELP!!!!!!!!!
> thanks for the prompt replies. > Sadly, still no joy. > > Tried the grant all but this did not help either. > > I have set up the yml file as per the tutorials. Sadly, I have gone > through the tutorial from agile web development line by line and still > not been able to achieve the "agility" promised. > > my yml file has this: > adapter: mysql > database: depot_test > username: > password:foo > socket: /path/to/your/mysql.sock > > I can log into mySQL from the command line so I figure that is set up > OK. > Is win XP the issue. I have a mac - I could upgrade to Tiger and > work on > that if that is a better environment. > > I would really like to make this work so I''m willing to try any > suggestions.My winXP comment was mostly tongue in cheek. I like to take shots at windows guys whenever possible. When asked, I always tell people that in the late 90''s there was a legitimate argument for whether windows was better than macintosh. However, starting with Apple''s adoption of a nix core they began to move ahead. In the last 3-4 years (while we''ve all been waiting for longhorn to mosey on in from the range), Apple has made such advances that using windows for any serious application (and most trivial applications as well) is just ludicrous. Windows has become a joke. Vista is the punchline. Oh, and before the Linux guys attack me ... I think linux is great as a server. In fact, I use it myself. But for my laptop, I prefer the macintosh gui over anything out there for linux. My only request, John, is that you remember to differentiate between the troubles setting up the database server, and the troubles using the framework. I had some user permissions problems as well when I first set up MySQL. I mostly use OpenBase, so I''m not really qualified to solve your MySQL problems, but please don''t reject such a great framework on account of those 5 lines in database.yml -Derrick Spell
john
2006-Mar-02 21:53 UTC
[Rails] Re: Re: can''t get rails to connect to mySQL - HELP!!!!!!!!!
Andrew VanSpronsen wrote: How can I thank you enough!!! I added in the host:localhost to the yml and that seems to have fixed things. Thanks very much for the input. I shall now give it another try (tomorrow). Derrick - agree there is a difference between setting up the database and using the framework and at the end of the day it will be me who is disadvantaged if I don''t master this - it''s just that I have loads of patience and reasonable (but not comprehensive) knowledge and struggling just to "open the box" as it were seemed to contradict the "agile" bit of ruby on rails. Anyway, I''m on rails now and the database is happy too... Once again, many thanks for all the input, I really appreciate it. -- Posted via http://www.ruby-forum.com/.
Ben Munat
2006-Mar-03 05:34 UTC
[Rails] Re: Re: can''t get rails to connect to mySQL - HELP!!!!!!!!!
john wrote:> Andrew VanSpronsen wrote: > > How can I thank you enough!!! > > I added in the host:localhost to the yml and that seems to have fixed > things. Thanks very much for the input.That''s odd... the ActiveRecord docs say that the default value for host *is* localhost. Not sure why adding it would make a difference.> I shall now give it another try (tomorrow). > > Derrick - agree there is a difference between setting up the database > and using the framework and at the end of the day it will be me who is > disadvantaged if I don''t master this - it''s just that I have loads of > patience and reasonable (but not comprehensive) knowledge and struggling > just to "open the box" as it were seemed to contradict the "agile" bit > of ruby on rails."Agile" comes after the learning curve... which can be quite long. I think the many powerful aspects of rails -- which tends to make for less code than in other languages/frameworks -- has unfortunately gotten mutated into "it''s so easy, anyone can do it", which is far, far from the truth. b> Anyway, I''m on rails now and the database is happy too... > > Once again, many thanks for all the input, I really appreciate it. > >
Derrick Spell
2006-Mar-03 15:48 UTC
[Rails] Re: Re: can''t get rails to connect to mySQL - HELP!!!!!!!!!
> > "Agile" comes after the learning curve... which can be quite long. > I think the many powerful aspects of rails -- which tends to make > for less code than in other languages/frameworks -- has > unfortunately gotten mutated into "it''s so easy, anyone can do it", > which is far, far from the truth.I agree. The statement should read, "It''s so easy, any experienced programmer can pick it up in a day". -Derrick
Ben Munat
2006-Mar-03 17:32 UTC
[Rails] Re: Re: can''t get rails to connect to mySQL - HELP!!!!!!!!!
Hmm, first the OT tirade about windows then this little piece of arrogance... I nominate Derrick king ogre of the list! (Though I''m well aware that my fastidious "best practices" dogma might earn me such a nomination as well). :-) b PS: I''d actually meet you halfway: "It''s so easy, any experienced *Ruby* programmer can pick it up in a day" (though they''ll still have trouble if they don''t understand web development). Derrick Spell wrote:>> >> "Agile" comes after the learning curve... which can be quite long. I >> think the many powerful aspects of rails -- which tends to make for >> less code than in other languages/frameworks -- has unfortunately >> gotten mutated into "it''s so easy, anyone can do it", which is far, >> far from the truth. > > > I agree. The statement should read, "It''s so easy, any experienced > programmer can pick it up in a day". > > -Derrick > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails
Derrick Spell
2006-Mar-03 17:35 UTC
[Rails] Re: Re: can''t get rails to connect to mySQL - HELP!!!!!!!!!
I''ll admit to some "ogre" tendencies lately. Chock it up to a really bad week...stress and all that... I''m really a nice guy once you get to know me :) Yes, I accept your patch to statement. I''ve committed it to the latest svn trunk. -Derrick On Mar 3, 2006, at 12:34 PM, Ben Munat wrote:> Hmm, first the OT tirade about windows then this little piece of > arrogance... I nominate Derrick king ogre of the list! (Though I''m > well aware that my fastidious "best practices" dogma might earn me > such a nomination as well). > > :-) > > b > > PS: I''d actually meet you halfway: "It''s so easy, any experienced > *Ruby* programmer can pick it up in a day" (though they''ll still > have trouble if they don''t understand web development). > > Derrick Spell wrote: >>> >>> "Agile" comes after the learning curve... which can be quite >>> long. I think the many powerful aspects of rails -- which tends >>> to make for less code than in other languages/frameworks -- has >>> unfortunately gotten mutated into "it''s so easy, anyone can do >>> it", which is far, far from the truth. >> I agree. The statement should read, "It''s so easy, any >> experienced programmer can pick it up in a day". >> -Derrick >> _______________________________________________ >> Rails mailing list >> Rails@lists.rubyonrails.org >> http://lists.rubyonrails.org/mailman/listinfo/rails > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
Ben Munat
2006-Mar-03 17:42 UTC
[Rails] Re: Re: can''t get rails to connect to mySQL - HELP!!!!!!!!!
LOL.... :-D b Derrick Spell wrote:> I''ll admit to some "ogre" tendencies lately. Chock it up to a really > bad week...stress and all that... I''m really a nice guy once you get > to know me :) > > Yes, I accept your patch to statement. I''ve committed it to the latest > svn trunk. > > -Derrick > > On Mar 3, 2006, at 12:34 PM, Ben Munat wrote: > >> Hmm, first the OT tirade about windows then this little piece of >> arrogance... I nominate Derrick king ogre of the list! (Though I''m >> well aware that my fastidious "best practices" dogma might earn me >> such a nomination as well). >> >> :-) >> >> b >> >> PS: I''d actually meet you halfway: "It''s so easy, any experienced >> *Ruby* programmer can pick it up in a day" (though they''ll still have >> trouble if they don''t understand web development). >> >> Derrick Spell wrote: >> >>>> >>>> "Agile" comes after the learning curve... which can be quite long. >>>> I think the many powerful aspects of rails -- which tends to make >>>> for less code than in other languages/frameworks -- has >>>> unfortunately gotten mutated into "it''s so easy, anyone can do >>>> it", which is far, far from the truth. >>> >>> I agree. The statement should read, "It''s so easy, any experienced >>> programmer can pick it up in a day". >>> -Derrick >>> _______________________________________________ >>> Rails mailing list >>> Rails@lists.rubyonrails.org >>> http://lists.rubyonrails.org/mailman/listinfo/rails >> >> _______________________________________________ >> Rails mailing list >> Rails@lists.rubyonrails.org >> http://lists.rubyonrails.org/mailman/listinfo/rails >> > > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails
Richard
2006-Mar-23 08:54 UTC
[Rails] Re: Re: Re: can''t get rails to connect to mySQL - HELP!!!!!!
Hey people I have a different problem with mysql Mysql::Error: Lost connection to MySQL server during query: SHOW FIELDS FROM recipes If i change the password in database.yml, it gives a nice ''could not log in'', so those settings are correct. If i log in to mysql for my user and run the above query, it gives the correct result. Any ideas of what i''m doing wrong? Richard -- Posted via http://www.ruby-forum.com/.
Chris Larson
2006-Mar-23 15:25 UTC
[Rails] Re: Re: Re: can''t get rails to connect to mySQL - HELP!!!!!!
What OS are you using? What version of MySQL are you connecting too? Is MySQL locally hosted? Chris On Mar 23, 2006, at 1:54 AM, Richard wrote:> Hey people > > I have a different problem with mysql > Mysql::Error: Lost connection to MySQL server during query: SHOW > FIELDS > FROM recipes > > If i change the password in database.yml, it gives a nice ''could > not log > in'', so those settings are correct. If i log in to mysql for my > user and > run the above query, it gives the correct result. > > Any ideas of what i''m doing wrong? > > Richard > > -- > Posted via http://www.ruby-forum.com/. > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails