While the recent implementation of database name suggestion in T287471 is helpful, it has numerous invalid entries. As mentioned in T287471#7300959, this doesn't do much validation, and so it suggests things like "commonwiki_p" instead of "commonswiki_p". Additionally, it won't suggest e.g. iuwiki_p, even though that's a perfectly valid database name.
With the new database structure, there's no obvious way of finding all of the valid database names. Running SELECT dbname from wiki; on meta_p gives all the wiki databases, but leaves out those such as meta_p itself. In addition to the wikis themselves, there are at least:
- meta_p
- centralauth_p
- information_schema
- information_schema_p
- heartbeat_p
though I don't believe this is exhaustive.