4 ms·
All of the ReQL examples are completely unreadable relative to SQL. Because SQL is very familiar and ReQL is not.
by untog 12y ago
All of the ReQL examples are completely unreadable relative to SQL.
Because SQL is very familiar and ReQL is not.
- sanderjd 12y agoI think it's more because the javascript-with-callbacks is chatty and ugly. But you can also write it in a more stream-like style. I have no idea why so many examples out there use the nastier style. An example stolen from another commenter: r.table('users').filter(r.row('age').gt(30))
- coffeemug 12y ago> I think it's more because the javascript-with-callbacks is chatty and ugly. We did the best we could with JavaScript. IMO the Ruby implementation of ReQL is dramatically more beautiful. Ruby's blocks fit so well that we don't even provide the `r.row` shortcut in ruby: r.table('users').filter{|row| row['age'] > 30}
- EvanYou 12y agoWith ES6: r.table('users').filter(row => row('age').gt(30))
- TylerE 12y agoYou only write javascript if you're using javascript ;) If you python you use python's native constucts, which if you use python you're naturally familiar with. r.table('users').filter(r.row['age'] > 30)