Home  >  Q&A  >  body text

How to use mysqli to determine whether a MySQL database exists in PHP?

How to use the mysqli statement in PHP to accurately determine whether a MySQL database exists?
How to determine whether a certain table in the database exists?

What do the two styles provided in the official PHP documentation mean?
Object-oriented style and process-oriented style.
Are these two styles just different in grammar? Or is the code logic written in different ways because it is object-oriented and process-oriented?

淡淡烟草味淡淡烟草味2708 days ago1031

reply all(1)I'll reply

  • 曾经蜡笔没有小新

    曾经蜡笔没有小新2017-06-14 10:51:52

    SQL statementshow databases can view all libraries (libraries with permission to access)
    show tablescan view which tables are in the currently selected database
    (or show tables from XXX)

    Or by accessing the built-in information_schema library of mysql, the tables table inside also has table information

    reply
    0
  • Cancelreply