Re: [Rails] ThinkingSphinx ConnectionError

2014-09-24 Thread M,Gopi M.gopinath
I have fixed this by killing the searchd and again started it. On Tue, Sep 23, 2014 at 9:46 PM, Hassan Schroeder hassan.schroe...@gmail.com wrote: On Tue, Sep 23, 2014 at 2:31 AM, M,Gopi M.gopinath gopi170...@gmail.com wrote: for me, But suddenly this functionality as been broken

Re: [Rails] Please help to me handling special characters in rails-sql

2014-09-24 Thread Vivek Sampara
Which database are you using ? And what is the encoding set on the environment ? On Wed, Sep 24, 2014 at 10:37 AM, Lekkala Kondareddy lekka...@gmail.com wrote: i have faced problem in my database has special characters please suggest any solutions -- You received this message because you

[Rails] Re: User on settings page

2014-09-24 Thread Mohammed Rashid
Thank you guys, I will have a look at these nice to know something like this is possible -- 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 unsubscribe from this group and stop receiving emails

[Rails] Controller / irb

2014-09-24 Thread Mohammed Rashid
This is my controller: class Members ActiveRecord::Base def name return name + end def describe return name + + email + + mobile + + category + + other end end when i go into the rails console and connect to Members, I say: a = Members.first a.name this should give me the

Re: [Rails] Controller / irb

2014-09-24 Thread Muskalek
That is because your name method is called recursively - the `return name + ` is calling `name` once again and again and again... If you want to access raw attributes from database on ActiveRecord models, you can always use `self[:name]`. It might be convenient for you to use ruby

[Rails] Rspec Active Record Problem

2014-09-24 Thread Jan Yo
Rspec forum isn't working Rspec is having trouble recognizing where method. Here's the rspec output: NoMethodError: undefined method `where' for #Article:0x00066ceb38 # /apps/rvm/gems/ruby-2.0.0-p481/gems/activemodel-4.0.10/lib/active_model/attribute_methods.rb:439:in

Re: [Rails] ThinkingSphinx ConnectionError

2014-09-24 Thread Hassan Schroeder
On Tue, Sep 23, 2014 at 11:27 PM, M,Gopi M.gopinath gopi170...@gmail.com wrote: I have fixed this by killing the searchd and again started it. Uh, well. I wouldn't say fixed if you don't know why your searchd instance became unresponsive and you haven't taken appropriate steps to insure that it

Re: [Rails] Rspec Active Record Problem

2014-09-24 Thread Jason Fleetwood-Boldt
Jan, That is pretty strange-- but it looks like you're doing something non-standard and you've gotten yourself into a pickle. I notice that the error message says there's no method 'where' on an instance of an Article. Normally you call where on the class itself. First of all, why is your

[Rails] Ruby rails

2014-09-24 Thread Morad
I installed Ruby on Rails 1.9.3 version on windows . I built a simple hello world program , the issue is that when I build it in sublime text 2 I get this error :Uninitialized constant ApplicationController ( nameerror) and I get the same error when run this program in the command line . My

[Rails] Re: Ruby rails

2014-09-24 Thread Frederick Cheung
On Wednesday, September 24, 2014 5:18:49 PM UTC+1, Morad wrote: The program : class HelloworldsController ApplicationController def hi puts Hello world end end Any thoughts pleas ? sublime text's build action just runs the current ruby file if my memory is correct. You

Re: [Rails] Please help to me handling special characters in rails-sql

2014-09-24 Thread Frederick Cheung
On Wednesday, September 24, 2014 9:57:13 AM UTC+1, Vivek Sampara wrote: Which database are you using ? And what is the encoding set on the environment ? To which I'd add: what is the problem? Fred On Wed, Sep 24, 2014 at 10:37 AM, Lekkala Kondareddy lekka...@gmail.com wrote: i

Re: [Rails] Ruby rails

2014-09-24 Thread Jason Fleetwood-Boldt
what exactly are you typing when you are run this program on the command line did you originally do rails new on the command line to create new rails app? On Sep 24, 2014, at 12:18 PM, Morad mb...@njit.edu wrote: I installed Ruby on Rails 1.9.3 version on windows . I built a simple hello

[Rails] Re: Controller / irb

2014-09-24 Thread Mohammed Rashid
Muskalek wrote in post #1158351: That is because your name method is called recursively - the `return name + ` is calling `name` once again and again and again... If you want to access raw attributes from database on ActiveRecord models, you can always use `self[:name]`. It might be

Re: [Rails] Ruby rails

2014-09-24 Thread Morad
Yes I did create the new project through the command prompt, then generated a controller for it ( Helloworlds) . I went into the directory where the project is and started the rail server , tested it and it comes up on the browser. While in the folder where the project is, issued command :

Re: [Rails] Ruby rails

2014-09-24 Thread Jason Fleetwood-Boldt
Who told you to run ruby helloworlds_conteoller.rb and why would you expect that output from executing that as a ruby script? In short, that's just not how Rails is built. Your webserver starts up the entire Rails app -- including loading all associated files and dependencies -- when you run

Re: [Rails] Rspec Active Record Problem

2014-09-24 Thread Alexandre Calvão
Try using scope http://guides.rubyonrails.org/active_record_querying.html#scopes. === *Alexandre Mondaini Calvão* *Nossa recompensa se encontra no esforço e não no resultado. Um esforço total é uma vitória completa*. [Ghandi] 2014-09-24 12:52 GMT-03:00 Jason Fleetwood-Boldt

[Rails] Check if Active Directory user account disabled

2014-09-24 Thread ZBoT ZBoT
Hi all, I am new to Rails and in my app I need to check if a user account is disabled in Active Directory. I am not using AD for Rails authentication. I've searched around and I'm getting overwhelmed with the answers. What would be the easiest way to go about this? Should I just do some type

Re: [Rails] Check if Active Directory user account disabled

2014-09-24 Thread Jason Fleetwood-Boldt
here are some options https://www.ruby-toolbox.com/search?utf8=%E2%9C%93q=active+directory On Sep 24, 2014, at 2:02 PM, ZBoT ZBoT li...@ruby-forum.com wrote: Hi all, I am new to Rails and in my app I need to check if a user account is disabled in Active Directory. I am not using AD for

[Rails] Re: Rspec Active Record Problem

2014-09-24 Thread Jan Yo
Jason Fb wrote in post #1158388: Jan, That is pretty strange-- but it looks like you're doing something non-standard and you've gotten yourself into a pickle. I notice that the error message says there's no method 'where' on an instance of an Article. Normally you call where on the class

Re: [Rails] Rspec Active Record Problem

2014-09-24 Thread Jason Fleetwood-Boldt
I think what apot...@gmail.com pointed out is most poignant, you can accomplish what you are trying to accomplish with this (ruby 2 syntax) scope :low_level, - { where(:level = 1) } The you reference this scope as Article.low_level as you get your hands dirty with AR scopes, read understand