Skip to main content
April 22, 2023
Question

Set Current Schema - PhpMyAdmin

  • April 22, 2023
  • 5 replies
  • 0 views

Hello Everyone,

How can I set current schema to a particular schema/database in phpmyAdmin to ensure I execute queries on tables within that schema only.

I tried with USE <Schema_Name> . This is not working. 

Regards,

SG

5 replies

stefanhelzle0001
Brainy
April 22, 2023

If this is only about executing some statements manually, then just navigate to the desired schema/table in the left hand panel.

April 23, 2023

Thanks Stefan,

Is it possible through query?

Regards,

Surjit

April 23, 2023

What are you trying to do? If your current/desired schema is selected (which you can see at the top) then you can simply run any script without the need to define database name.

Still if you want to define database name in your query then just simply but it before the table name.

Example:

SELECT * FROM SCHEMA_NAME.TABLE_NAME WHERE 1;

harshitb6843
April 22, 2023

As stefan said, you can simply click on the schema name and also verify the same as in the image below.