Skip to content

Hydrahon v1.1.5

Compare
Choose a tag to compare
@mario-deluna mario-deluna released this 25 Aug 15:17
· 105 commits to master since this release

Features

I've added an EXISTS query object allowing you to do a query like this one:

SELECT EXISTS(select id from showtimes) as hasShows

Like that:

$h->table('showtimes')->select()->exists(); // returns bool true

Obviously that select query can do everything like the normal select.

$h->table('showtimes')
    ->select()
    ->where(function($q)
    {
        $q->where('start', '>', time());
        $q->orWhere('end', '<', time() + 3600);
    })
    ->exists();