PHPackages                             marwelln/exists - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. marwelln/exists

ActiveLibrary[Database &amp; ORM](/categories/database)

marwelln/exists
===============

Run exists queries in Laravel

v1.0.5(5y ago)031MITPHPPHP &gt;=7.0

Since Jun 1Pushed 5y ago1 watchersCompare

[ Source](https://github.com/Marwelln/Exists)[ Packagist](https://packagist.org/packages/marwelln/exists)[ RSS](/packages/marwelln-exists/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (6)Dependencies (1)Versions (7)Used By (0)

Installation
============

[](#installation)

```
composer require marwelln/exists:~1.0

```

Usage
=====

[](#usage)

```
$exists = Marwelln\Exists::table('mytable')->where('statement', 'value')->check(); // true or false

$exists = (new Marwelln\Exists('mytable'))->where('statement', 'value')->check(); // true or false

```

Available methods
=================

[](#available-methods)

```
static table(string $table)

```

Sets the table we want to run `EXISTS` with. Can use constructor instead if wanted.

```
where(string $key, mixed $value, string $operator = '=') // WHERE key {$operator} value

whereBetween(string $key, string $field1, string $field2) // WHERE key BETWEEN field1 AND field2

whereNull(string $key) // WHERE key IS NULL

whereNotNull(string $key) // WHERE key IS NOT NULL

```

Add `WHERE` statements. This can be chained.

```
check()
// SELECT EXISTS(SELECT 1 FROM table WHERE statements) AS `exists`

```

Run the query. Will return `true` or `false` depending on if the row existed or not.

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity62

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~314 days

Total

6

Last Release

2109d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0e5e4d36e4b85e220991cbc37adec7a61b195172c53933bf0e3902a218be08eb?d=identicon)[Marwelln](/maintainers/Marwelln)

---

Top Contributors

[![Marwelln](https://avatars.githubusercontent.com/u/128591?v=4)](https://github.com/Marwelln "Marwelln (9 commits)")

### Embed Badge

![Health badge](/badges/marwelln-exists/health.svg)

```
[![Health](https://phpackages.com/badges/marwelln-exists/health.svg)](https://phpackages.com/packages/marwelln-exists)
```

###  Alternatives

[kirschbaum-development/eloquent-power-joins

The Laravel magic applied to joins.

1.6k29.9M42](/packages/kirschbaum-development-eloquent-power-joins)[mongodb/laravel-mongodb

A MongoDB based Eloquent model and Query builder for Laravel

7.1k8.0M88](/packages/mongodb-laravel-mongodb)[yajra/laravel-oci8

Oracle DB driver for Laravel via OCI8

8723.1M23](/packages/yajra-laravel-oci8)[staudenmeir/laravel-adjacency-list

Recursive Laravel Eloquent relationships with CTEs

1.6k5.2M33](/packages/staudenmeir-laravel-adjacency-list)[bavix/laravel-wallet

It's easy to work with a virtual wallet.

1.3k1.2M19](/packages/bavix-laravel-wallet)[glushkovds/phpclickhouse-laravel

Adapter of the most popular library https://github.com/smi2/phpClickHouse to Laravel

2051.4M2](/packages/glushkovds-phpclickhouse-laravel)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
