GitXplorerGitXplorer
t

randomizr

public
1 stars
2 forks
0 issues

Commits

List of commits on branch master.
Unverified
0271acc76f0e79c1b929dff5f291b74aae49d3f7

Drop the runtime dependency on Active Record.

ttilsammans committed 13 years ago
Unverified
5d2f87558584f98e6ea9451e910c3a67171dab64

release 1.0

ttilsammans committed 13 years ago
Unverified
e8380e2fe72ab3fc484e04533b7e4969edd456f7

add teh codez

ttilsammans committed 13 years ago
Unverified
b72d25de900814c36334480a5a435548959805fe

added descriptions

ttilsammans committed 13 years ago
Unverified
9f09173abae2cd0b6318142f7f2fbc387d26fae7

bundle gem randomizr

ttilsammans committed 13 years ago

README

The README file for this repository.

= Randomizr

Returns one random Active Record object using cross-platform ANSI compliant SQL.

We have all used order by rand() to select a random record from time to time. We know we shouldn't, but it was just too easy. Well no more. NO MORE. It's now +easier+ to do it properly by just using this gem. That's right. It will solve all your ansi-sql troubles and put that smile back on your face.

== Prerequisites

Active Record, of course. Any version 2 or 3 will do.

== Installation

config.gem 'randomizr'

or in your Gemfile:

gem 'randomizr'

I told you installation would be easy.

== Examples

Comment.randomizr # => look ma, a random comment!

Copyright (c) 2011 Joost Baaij, released under the MIT license