Skip to content

NC21, postgres, Doctrine\DBAL\Query\QueryException: More than 1000 expressions in a list are not allowed on Oracle. #4584

@joergmschulz

Description

@joergmschulz

Actual behavior

Using mail on a dovecot mailbox with > 1000 messages.
The app tends to timeout and make the browser think it stopped.
The log displays:
[core] Error: Doctrine\DBAL\Query\QueryException: More than 1000 expressions in a list are not allowed on Oracle. at <>

  1. /www/nextcloud/custom-apps/mail/lib/Db/MessageMapper.php line 764
    OC\DB\QueryBuilder\QueryBuilder->execute()
  2. /www/nextcloud/custom-apps/mail/lib/Db/MessageMapper.php line 742
    OCA\Mail\Db\MessageMapper->findRecipients([OCA\Mail\Db\Mes ... "])
  3. /www/nextcloud/custom-apps/mail/lib/Service/Sync/SyncService.php line 158
    OCA\Mail\Db\MessageMapper->findByIds([55535,44431,444 ... "])
  4. /www/nextcloud/custom-apps/mail/lib/Service/Sync/SyncService.php line 126
    OCA\Mail\Service\Sync\SyncService->getDatabaseSyncChanges(OCA\Mail\Account {}, OCA\Mail\Db\Mailbox {id: 167}, [61398,61397,613 ... "], OCA\Mail\Service\Search\SearchQuery {})
  5. /www/nextcloud/custom-apps/mail/lib/Controller/MailboxesController.php line 161
    OCA\Mail\Service\Sync\SyncService->syncMailbox(OCA\Mail\Account {}, OCA\Mail\Db\Mailbox {id: 167}, 42, [61398,61397,613 ... "], true, "is:pi-other")
  6. /www/nextcloud/lib/private/AppFramework/Http/Dispatcher.php line 218
    OCA\Mail\Controller\MailboxesController->sync(167, [61398,61397,613 ... "], false, "is:pi-other")
  7. /www/nextcloud/lib/private/AppFramework/Http/Dispatcher.php line 127
    OC\AppFramework\Http\Dispatcher->executeController(OCA\Mail\Control ... {}, "sync")
  8. /www/nextcloud/lib/private/AppFramework/App.php line 157
    OC\AppFramework\Http\Dispatcher->dispatch(OCA\Mail\Control ... {}, "sync")
  9. /www/nextcloud/lib/private/Route/Router.php line 302
    OC\AppFramework\App::main("OCA\Mail\Cont ... r", "sync", OC\AppFramework\ ... {}, {id: "167",_route: "mail.mailboxes.sync"})
  10. /www/nextcloud/lib/base.php line 993
    OC\Route\Router->match("/apps/mail/api/mailboxes/167/sync")
  11. /www/nextcloud/index.php line 37
    OC::handleRequest()

POST /index.php/api/mailboxes/167/sync
f

Mail app

Mail app version:
1.8.3

Mailserver or service:
dovecot imap

Server configuration

Operating system:
Alpine, dockerized

Web server:
nginx

Database: (e.g. MariaDB, SQLite or PostgreSQL)
postgresql

PHP version: (e.g. 7.0)
7.4
Nextcloud Version: (see admin page, e.g. 13.0.2)
21.0.0

Client configuration

Browser: (e.g. Firefox 48)
current firefox

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions