Skip to content

Instantly share code, notes, and snippets.

@donovanbray
Created January 6, 2012 00:54
Show Gist options
  • Save donovanbray/1568266 to your computer and use it in GitHub Desktop.
Save donovanbray/1568266 to your computer and use it in GitHub Desktop.
The users in staging test database need to be subscribed to a national deal.
def testme
p = User.where("email like '%offerify.net'" )
p.each_with_index {|user,i|
puts 'so far - ' + i.to_s + Time.now.to_s if i % 500 == 0
@params = {:user_id=>user.id, :region=>Region.national.first, :partner=>$current_partner, :is_midday_subscribed=>false, :is_pr_subscribed=>false}
Subscription.create(@params)
}
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment