mysql – The Postmap database returns an error not found

I have configured my Postfix configuration with Mysql maps, as detailed here and here.

I have a file in /etc/postfix/mysql-virtual-mailbox-maps.cf that contains the following:

    user = mailuser
password = fLxsWdf5ABLqwhZr
hosts = 127.0.0.1
dbname = mailserver
query = SELECT 1 FROM virtual_users WHERE email = & # 39;% s & # 39;

this is linked to /etc/postfix/main.cf with the following line:

virtual_mailbox_domains = mysql: /etc/postfix/mysql-virtual-mailbox-domains.cf

When I use postmap

postmap -qv dave@example.co.za mysql: /etc/postfix/mysql-virtual-mailbox-domains.cf

I got the following error:

fatal: open the database dave@example.co.za.db: There is no such file or directory

Clearly there is no database "dave@example.co.za.db" but I hope it will be seen in the "mailserver" database.