Skip to content

Commit

Permalink
Queries must now be select statements
Browse files Browse the repository at this point in the history
  • Loading branch information
Oliver Searle-Barnes committed Mar 22, 2010
1 parent 2bd0a16 commit f4264e1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions app/models/report.rb
@@ -1,4 +1,5 @@
class Report < ActiveRecord::Base
attr_accessible :name, :query, :database_id
belongs_to :database
validates_format_of :query, :with => /^select.*/, :message => 'must be a select statement'
end

0 comments on commit f4264e1

Please sign in to comment.