php-imap icon indicating copy to clipboard operation
php-imap copied to clipboard

orWhere() and andWhere() Not Working in Query

Open FahimSakib opened this issue 10 months ago • 0 comments

I am facing an issue with the orWhere() and andWhere() query functions. Whenever I use orWhere(), it returns an empty response. I couldn't find any documentation related to these functions, so I'm unsure if I'm using them correctly.

Here’s the code snippet I’m using:

 $query = $inbox->query()
    ->where('FROM', $this->fromEmailAddress)
    ->orWhere(function ($query) {
        $query->where('SUBJECT', 'Test');
    });

Could you please confirm whether orWhere() and andWhere() are supported? If so, am I using them correctly? Any guidance or documentation would be appreciated.

FahimSakib avatar Feb 04 '25 12:02 FahimSakib