Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better to add ".one" at the end for queries which uses limit #415

Open
charlesskariah opened this issue Nov 7, 2017 · 0 comments
Open

Comments

@charlesskariah
Copy link

charlesskariah commented Nov 7, 2017

In certain part of documentation follow this link , .one is used and the reason is that it throws error if nothing found using limit, while making use of .one it will return nil.I think it must be a standard to use .one for all the queries where we use .limit.

http://hanamirb.org/guides/1.0/models/sql-queries/
In the above link under section limit, this can be added

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant