It is a direct port of https://github.com/rails/arel, with a couple of changes. It was built so Node JS could be used for some more serious projects that most people were/are still tackling with Ruby. All feedback is welcome and if you find any issues please raise them in the issues section on github. Patches will be accepted as long as they are tested. For more details checkout the Github page.
users = new Rel.Table 'users'
users.project(Rel.star()).toSql()
The above produces
SELECT * FROM users
users.where(users.column('name').eq('amy')).project(users.column('id'))
This generates some fanciness
SELECT users.id FROM users WHERE users.name = 'amy'
npm install rel
Built by Carl Woodward — @cjwoodward for 88cartell.
The software is developed under the MIT License.
For more examples and details look at the Github page.