uteq/laravel-query-builder-macros
Larablocks Analysis
uteq/laravel-query-builder-macros works with Laravel 8, 9 and 10 (latest release 1.0.8, Mar 26, 2023), all past end of life (the last on Feb 4, 2025): no more fixes, even for security.
Recommendation checks
Not advisedNot advised: no release or commit in over 2 years.
- No release or commit in over 2 years
- Supports only Laravel 8, 9 and 10, past end of life since Feb 4, 2025
- No release in the last 12 months (last: Mar 26, 2023)
- 7 downloads a month (needs 10,000)
- 20 GitHub stars (needs 100)
State
Likely abandoned- No release or commit in over 2 years.
- Last stable release: Mar 26, 2023.
- No releases in the last 12 months.
- First released: Mar 25, 2023.
- Monthly downloads: 7.
- 0 open issues on GitHub.
Data from Packagist and GitHub, checked by Larablocks on Nov 29, 2026.
| Install | |
|---|---|
composer require uteq/laravel-query-builder-macros |
|
| Latest Version: | 1.0.8 |
| PHP: | ^8.0 |
| Laravel: | 8 · 9 · 10 |
| License: | MIT |
| Last Updated: | Mar 26, 2023 |
| Links: | GitHub · Packagist |
A set of useful macros for the query builder
Adds useful functionality to the Laravel Query Builder
Illuminate\Database\Query\Builder.
Installation
composer require uteq/laravel-query-builder-macros
Or add the Uteq Laravel Support package
composer require uteq/laravel-support
rawQuery
$rawQuery = Account::query()
->where('email', 'john')
->getQuery() // You need to do this to get the rawQuery
->rawQuery();
// return `select * from "account" where "email" = 'john'`
ddQuery
Account::query()
->where('email', 'john')
->ddQuery();
// dd() of `select * from "account" where "email" = 'john'`
dumpQuery
Account::query()
->where('email', 'john')
->dumpQuery();
// dump() of `select * from "account" where "email" = 'john'`
// the execution of the script will continue
rayQuery
Account::query()
->where('email', 'john')
->rayQuery();
// ray() of `select * from "account" where "email" = 'john'`
// the execution of the script will continue
Inspiration by
Building this package I got inspired by the following:
- https://stackoverflow.com/a/53337416
- http://github.com/spatie/laravel-collection-macros
- https://github.com/spatie/package-skeleton-laravel
Credits
Testing
$ composer test
About Uteq
We are a web development agency based in the Netherlands. We design and build web applications for our clients. We are specialized in Laravel with Livewire.
License
The MIT License (MIT). Please see License File for more information.
Related Packages
Powerful PHP database abstraction layer (DBAL) with many features for database s...
Version History
| Version | Released | PHP | Laravel | License |
|---|---|---|---|---|
| 1.0.8 | ^8.0 | ^8.71| | MIT | |
| 1.0.7 | ^8.0 | ^8.71| | MIT | |
| 1.0.6 | ^8.0 | ^8.71| | MIT | |
| 1.0.5 | ^8.0 | ^8.71| | MIT | |
| 1.0.4 | ^8.0 | ^8.71| | MIT | |
| 1.0.3 | ^8.0 | ^8.71| | MIT | |
| 1.0.2 | ^8.0 | ^8.71| | MIT | |
| 1.0.1 | ^8.0 | ^8.71| | MIT | |
| 1.0.0 | ^8.0 | ^8.71| | MIT |