Overlay database engine exposes the union of the tables of several existing databases.
Creating a database
Alias table to the table of the source database: reading and writing go to the source table.
CREATE, DROP, RENAME, ATTACH and DETACH of tables inside the overlay database are not supported.
The source databases are resolved by name on every access: when a source database is dropped, its tables disappear from the overlay database, and they reappear when it is created again.
An Overlay database cannot be used as a source of another Overlay database.
Access control
As for anAlias table, working with a table of the overlay database requires the grants both on the overlay database and on the source table, and the row policies of both apply.
A table of the overlay database is visible only to a user who can see both the overlay database and the source table (the SHOW TABLES privilege on both).
A name is resolved in the first source database where the user can see a table with this name: a table that is hidden from the user is skipped, as if it did not exist.