Hi everyone:

Thanks for all the input here.  My datasource is parsing the
parameters correctly and I've got it hooked up to a fancy Google
motion chart which is why I was doing this in the first place.

I've also ordered a copy of The RSpec Book so it looks like I'm going
to have some reading to do soon!

I did have one more question about running SQL queries in Rails.  I'm
defining a set of reports which can contain arbitrary SQL which can be
executed to produce data for my graphs.  I've been able to get a raw
database connection using ActiveRecord::Base.connection which I can
use to execute my SQL, however I'm not sure how to properly escape
parameters I'm passing in to my queries if I want to prevent SQL
injection attacks.  What is a safe way to escape these values?  I feel
like I'm not generating the data for these reports "the Rails way".

Any thoughts?

On Aug 18, 7:10 pm, suranyami <[email protected]> wrote:
> There are also some quite good screencasts on rspec that covers
> speccing controllers and views over at:
>
> http://peepcode.com
>
> On Aug 18, 3:09 pm, Nathan de Vries <[email protected]> wrote:
>
>
>
> > On 18/08/2009, at 1:41 PM, Sonia Hamilton wrote:
>
> > > Ruby in Practice by Jeremy McAnally and Assaf Arkin (Paperback - Mar  
> > > 28, 2009)
>
> > Yep, that's a pretty good book. I would also recommend getting your  
> > hands on a copy of The RSpec Book [1], which goes through RSpec  
> > (obviously), cucumber, mocking, integration tests, webrat etc. Much of  
> > the content found online to do with TDD/BDD is the result of  
> > developers playing with a tool for a few minutes and then excitedly  
> > recommending or mouthing off about it. Books are your best bet in this  
> > regard. Once you've got your head around it all, you'll be able to  
> > pick the difference between ideology and good recommendations.
>
> > So even if you don't use all the tools recommended in The RSpec Book,  
> > I still think it's good for learning the whole testing stack so you  
> > have a point of comparison when evaluating all the other tools out  
> > there.
>
> > Cheers,
>
> > Nathan de Vries
>
> > [1]http://pragprog.com/titles/achbd/the-rspec-book

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to