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

Adds function value and sole_value to QueryBuilder & Model. #838

Merged
merged 2 commits into from
Sep 30, 2023

Conversation

JarriqTheTechie
Copy link
Contributor

@JarriqTheTechie JarriqTheTechie commented Feb 1, 2023

Eg.

remember_token = User.find(1).value("remember_token")

or

remember_token = User.where("email", "[email protected]").sole_value("remember_token")

@JarriqTheTechie
Copy link
Contributor Author

@josephmancuso please review.

@JarriqTheTechie JarriqTheTechie changed the title Get a single column's value from the first result of a query. Adds function value and sole_value to QueryBuilder & Model. Feb 1, 2023
@josephmancuso josephmancuso merged commit f2d57f7 into MasoniteFramework:2.0 Sep 30, 2023
@JarriqTheTechie JarriqTheTechie deleted the feature/value branch December 10, 2023 18:11
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

Successfully merging this pull request may close these issues.

2 participants