HostArmada Web Hosting Knowledge Base

Knowledge is power! Use that power and achieve total and unconditional control over the Web Hosting Services!

How to search your database using phpMyAdmin?

phpMyAdmin is a free, open-source, web-based MySQL administration tool written in PHP. Using it, you can perform actions such as:

  • Create a database
  • Delete a database
  • Modify a database table
  • Add or delete database fields
  • Use SQL code
  • Manage your keys

This feature is fully integrated with the web hosting service we offer at HostArmada, and you can easily access it from the cPanel.

Searching for strings or integers within your database using this robust tool, can be very useful in certain situations. For example, when you have changed the domain of your website, however, there are still entries in your database redirecting or loading content from the old domain name. PhpMyAdmin has a wide variety of functionalities that can efficiently help you find these records and replace them if needed.

In this article, we will take you through the process of searching your database using phpMyAdmin. We are also going to introduce you to a few techniques you can use to replace all matches of your search.

Here are the steps you need to follow to perform the lookup:

  • Log into your cPanel account.
  • Please use the search field on the top right corner and type in "phpMyAdmin". After the result presents itself underneath the search field, please click on it. Alternatively, you can navigate to the "Databases" features group and choose the "phpMyAdmin" tool.

 

Access the 'phpMyAdmin' tool in cPanel

 

  • This act will redirect you to the phpMyAdmin interface, and on the left side, you will see a column containing a list of all your databases on the server. Please click on the database where you want to perform the search. If you are not sure which is the database for your website, please log in via SSH and navigate to the root directory of the application, using the Linux Command Line Basics. When you are inside, please run the following command:
    grep 'username_' * -Ril 
    Here is an example:
    grep 'hostaramda_' * -Ril 
    The output will show you the database of your website!
  • When you are sure which is the correct database, please click on it.
  • Upon doing the above, all of the tables will be displayed in the middle of the screen. Above them, you will see a lot of tabs. Each of these tabs serves a specific purpose. The one you need to click on is the "Search" tab.

 

phpMyAdmin Database Search Function

 

  • After clicking on it, you will be redirected to the "Search" page, and on the top, you will see a text field. Inside this text field, please type in the string you want to find.
  • Underneath, you will see the "Find" section, containing a few options you can choose from. Please select the "all of the words" option using the radio button.
  • Below, you will find the "Inside tables" section. There will be a content box inside, allowing you to select the database table you want to search inside. Above the content box, there will be two buttons - "Select all" and "Unselect all" allowing you to either select or unselect all the tables of your database, held in the content box.
  • Lastly, beneath the content box, you will see a text field. You may use it to specify the column within the specific database table(s) where you want the search to be performed.
  • When you have configured the search pattern, please click on the "Go" button located on the bottom right corner of the page.

 

Search MySQL Database for a String in phpMyAdmin

 

  • This action will present a list of all the database tables you selected on the previous page. On the left side of this list, you will see the number of matches for every table.

Was this article useful and on point?

Find out more about HostArmada entire range of optimized Web Hosting Services and take action today on improving your website Loading Speed, Security, and overall Stability!