{"id":19259,"date":"2021-04-08T03:11:00","date_gmt":"2021-04-08T08:11:00","guid":{"rendered":"https:\/\/www.rosehosting.com\/blog\/?p=19259"},"modified":"2022-12-19T06:20:26","modified_gmt":"2022-12-19T12:20:26","slug":"mysql-show-users","status":"publish","type":"post","link":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/","title":{"rendered":"MySQL SHOW USERS: List All Users in a MySQL Database"},"content":{"rendered":"<div id=\"bsf_rt_marker\"><\/div>\r\n<figure class=\"wp-block-image\"><img decoding=\"async\" width=\"742\" height=\"372\" class=\"wp-image-30747\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2019\/05\/mysql-show-users.jpg\" alt=\"\" srcset=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2019\/05\/mysql-show-users.jpg 742w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2019\/05\/mysql-show-users-150x75.jpg 150w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2019\/05\/mysql-show-users-300x150.jpg 300w\" sizes=\"(max-width: 742px) 100vw, 742px\" \/><\/figure>\r\n\r\n\r\n\r\n<p>Today we are going to guide you on <strong>how to show all users in the MySQL users Database<\/strong>.<\/p>\r\n\r\n\r\n\r\n<div class=\"wp-block-image\">\r\n<figure class=\"alignright is-resized\"><img decoding=\"async\" class=\"wp-image-33650\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/list-MySQL-users.png\" alt=\"list MySQL users\" width=\"113\" height=\"113\" srcset=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/list-MySQL-users.png 225w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/list-MySQL-users-150x150.png 150w\" sizes=\"(max-width: 113px) 100vw, 113px\" \/><\/figure>\r\n<\/div>\r\n\r\n\r\n\r\n<p>A common question that most beginner MySQL users ask is &#8220;How do I see all of the users in my MySQL server?&#8221; Most of them assume that there is a<strong>\u00a0show users<\/strong>\u00a0command in MySQL,\u00a0but there isn&#8217;t one. This is a common mistake because there are other MySQL commands for displaying information about the database. For example, <code>SHOW DATABASES<\/code> will show us all of the databases that are present in our <a href=\"https:\/\/www.rosehosting.com\/mysql-hosting\/\">MySQL Server<\/a>, and\u00a0<code>SHOW TABLES<\/code> will show us all the tables in the <a href=\"https:\/\/www.rosehosting.com\/blog\/how-to-list-all-databases-in-mysql\/\">MySQL database<\/a> that you have selected.<\/p>\r\n\r\n\r\n\r\n<p>It&#8217;s not unusual for people to assume that there should be a <code>SHOW USERS<\/code> command in MySQL. Even though there isn&#8217;t a specific command for it, there are several ways to actually see the list of users and even filter them to see exactly what you need. This can all be done with the MySQL command line tool &#8211; let&#8217;s get started.<\/p>\r\n\r\n\r\n\r\n<p><!--more--><\/p>\r\n\r\n\r\n\r\n<p>Once you are logged in to your Linux server, execute the following command to log in to the MySQL command line interface.<\/p>\r\n\r\n\r\n\r\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_82_2 counter-hierarchy ez-toc-counter ez-toc-transparent ez-toc-container-direction\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<label for=\"ez-toc-cssicon-toggle-item-69c6355229ddc\" class=\"ez-toc-cssicon-toggle-label\"><span class=\"ez-toc-cssicon\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/label><input type=\"checkbox\"  id=\"ez-toc-cssicon-toggle-item-69c6355229ddc\"  aria-label=\"Toggle\" \/><nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#Log-in-to-your-MySQL-Server\" >Log in to your MySQL Server<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#MySQL-Show-Users-Command\" >MySQL Show Users Command<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#Display-Only-Unique-Usernames-in-MySQL-Database\" >Display Only Unique Usernames in MySQL Database<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#MySQL-User-table-Information\" >MySQL User table Information<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#Show-Information-About-Current-User\" >Show Information About Current User<\/a><\/li><\/ul><\/nav><\/div>\n<h2 class=\"wp-block-heading\" id=\"h-log-in-to-your-mysql-server\"><span class=\"ez-toc-section\" id=\"Log-in-to-your-MySQL-Server\"><\/span><img decoding=\"async\" class=\"alignright wp-image-30953 size-full\" title=\"how to show all users in a mysql database\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/how-to-show-all-users-in-a-mysql-database.jpg\" alt=\"how to show all users in a mysql database\" width=\"150\" height=\"150\" \/>Log in to your MySQL Server<span class=\"ez-toc-section-end\"><\/span><\/h2>\r\n\r\n\r\n\r\n<p>Log in as root to your MySQL server using the following command:<br \/><br \/><\/p>\r\n\r\n\r\n\r\n<pre id=\"block-7227abf1-8a34-4cd2-9e06-683937520304\" class=\"wp-block-preformatted\">mysql -u root -p<\/pre>\r\n\r\n\r\n\r\n<p>Then enter your MySQL root password. It is not set by default, so all you need to do is press the [Enter] key if you never set it. However, if you have set the password (whether with the <code>mysql_secure_installation<\/code> script or something else), you should enter that password now.<\/p>\r\n\r\n\r\n\r\n<h2 class=\"wp-block-heading\" id=\"h-mysql-show-users-command\"><span class=\"ez-toc-section\" id=\"MySQL-Show-Users-Command\"><\/span>MySQL Show Users Command<span class=\"ez-toc-section-end\"><\/span><\/h2>\r\n\r\n\r\n\r\n<div class=\"wp-block-image\">\r\n<figure class=\"alignleft\"><img decoding=\"async\" width=\"117\" height=\"100\" class=\"wp-image-30954\" title=\"mysql show all users\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/mysql-show-all-users-1.jpg\" alt=\"mysql show all users\" \/><\/figure>\r\n<\/div>\r\n\r\n\r\n\r\n<p>&nbsp;<\/p>\r\n\r\n\r\n\r\n<p><span style=\"background-color: #ffffff; color: #333333;\">We&#8217;ll just to query the User table to show all MySQL Users with the following command:<\/span><\/p>\r\n\r\n\r\n\r\n<pre class=\"wp-block-preformatted\">SELECT User, Host, Password FROM mysql.user;<\/pre>\r\n\r\n\r\n\r\n<p>The<strong> list of all MySQL users<\/strong> should be similar to the one below:<\/p>\r\n\r\n\r\n\r\n<pre class=\"wp-block-preformatted\">+------------------+--------------+--------------+\r\n| user             | host         | password     |\r\n+------------------+--------------+--------------+\r\n| root             | localhost    | 37as%#8123fs |\r\n| debian-test-user | localhost    | HmBEqPjC5Y   |\r\n| johnsm           | localhost    |              |\r\n| brian            | localhost    |              |\r\n| root             | 111.111.111.1|              |\r\n| guest            | %            |              |\r\n| adrianr          | 10.11.12.13  | RFsgY6aiVg   |\r\n+------------------+--------------+--------------+\r\n7 rows in set (0.01 sec)\r\n<\/pre>\r\n\r\n\r\n\r\n<p>If you want to add more columns or exclude some, just edit the command with the columns you need. You may only need the names of the users, so you can use <code> SELECT User FROM mysql.user;<\/code><\/p>\r\n\r\n\r\n\r\n<p>Another way to see all users is to simply use the asterisk (*) wildcard when selecting fields from the user table. It should look like this:<\/p>\r\n\r\n\r\n\r\n<pre class=\"wp-block-preformatted\">SELECT * FROM mysql.user;<\/pre>\r\n\r\n\r\n\r\n<p>This will return <strong>all<\/strong> possible field information for each user. Be aware that the number of fields is typically very long\/extensive, so the output likely won&#8217;t be readable and you probably don&#8217;t need all of the information available for each user. This is why we suggest specifying the field names, that way the output will be easily readable, and you&#8217;ll only see the information that you need.<\/p>\r\n\r\n\r\n\r\n<p>Some of the fields are related to privileges and permissions that each user has (such as &#8220;Insert_priv&#8221; or &#8220;Drop_priv&#8221;), and some fields are for the general properties of the user account, such as &#8220;max_connections&#8221; or &#8220;max_updates&#8221;.<\/p>\r\n\r\n\r\n\r\n<h2 class=\"wp-block-heading\" id=\"h-display-only-unique-usernames-in-mysql-database\"><span class=\"ez-toc-section\" id=\"Display-Only-Unique-Usernames-in-MySQL-Database\"><\/span>Display Only Unique Usernames in MySQL Database<span class=\"ez-toc-section-end\"><\/span><\/h2>\r\n\r\n\r\n\r\n<div class=\"wp-block-image\">\r\n<figure class=\"alignright\"><img decoding=\"async\" width=\"120\" height=\"101\" class=\"wp-image-30955\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/show-users-in-mysql.jpg\" alt=\"show users in mysql\" \/><\/figure>\r\n<\/div>\r\n\r\n\r\n\r\n<p>In some cases, selecting the user table can have duplicate results (e.g. one user for different hosts, but the users have the same name) &#8211; this can create clutter, so you may want to display only unique usernames.<\/p>\r\n\r\n\r\n\r\n<p>If you want to display only unique usernames that won&#8217;t be repeated in more rows, you can use <code> SELECT DISTINCT User FROM mysql.user;<\/code>, which should give you this output:<\/p>\r\n\r\n\r\n\r\n<pre class=\"wp-block-preformatted\">+------------------+\r\n| user             | \r\n+------------------+\r\n| root             | \r\n| debian-test-user | \r\n| johnsm           | \r\n| brian            | \r\n| guest            | \r\n| adrianr          | \r\n+------------------+\r\n6 rows in set (0.01 sec)<\/pre>\r\n\r\n\r\n\r\n<p>No repeated rows, just like we wanted. This can give you a clean look at what users exist on the database server. If you want, check out our guide on how to <a href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-mysql-database-on-ubuntu-20-04\/\">install MySQL database on Ubuntu 20.04<\/a>.<\/p>\r\n\r\n\r\n\r\n<h2 class=\"wp-block-heading\" id=\"h-mysql-user-table-information\"><span class=\"ez-toc-section\" id=\"MySQL-User-table-Information\"><\/span>MySQL User table Information<span class=\"ez-toc-section-end\"><\/span><\/h2>\r\n\r\n\r\n\r\n<div class=\"wp-block-image\">\r\n<figure class=\"alignright\"><img decoding=\"async\" width=\"99\" height=\"120\" class=\"wp-image-30956\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/mysql-showing-users.jpg\" alt=\"mysql showing users\" \/><\/figure>\r\n<\/div>\r\n\r\n\r\n\r\n<p><span style=\"font-family: Open Sans, sans-serif;\">As we mentioned in Step 2, there are many fields that you could use to see specific properties of your users. With this next command, you&#8217;ll be able to see all of the fields that your MySQL server supports. To see all the fields in the <\/span><span style=\"color: #555555;\"><span style=\"font-family: Open Sans, sans-serif;\"><span style=\"font-size: medium;\">mysql.user <\/span><\/span><\/span><span style=\"color: #555555;\"><span style=\"font-family: Open Sans, sans-serif;\"><span style=\"font-size: medium;\">table containing a description related to the user table, run the following MySQL command to query the database.<\/span><\/span><\/span><\/p>\r\n\r\n\r\n\r\n<pre class=\"wp-block-preformatted\">mysql&gt; desc mysql.user;<\/pre>\r\n\r\n\r\n\r\n<p>The output will look similar to the one below. There are a lot of options!:<\/p>\r\n\r\n\r\n\r\n<pre class=\"wp-block-preformatted\">mysql&gt; desc mysql.user;\r\n+------------------------+-----------------------------------+------+-----+-----------------------+-------+\r\n| Field                  | Type                              | Null | Key | Default               | Extra |\r\n+------------------------+-----------------------------------+------+-----+-----------------------+-------+\r\n| Host                   | char(60)                          | NO   | PRI |                       |       |\r\n| User                   | char(16)                          | NO   | PRI |                       |       |\r\n| Password               | char(41)                          | NO   |     |                       |       |\r\n| Select_priv            | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Insert_priv            | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Update_priv            | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Delete_priv            | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Create_priv            | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Drop_priv              | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Reload_priv            | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Shutdown_priv          | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Process_priv           | enum('N','Y')                     | NO   |     | N                     |       |\r\n| File_priv              | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Grant_priv             | enum('N','Y')                     | NO   |     | N                     |       |\r\n| References_priv        | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Index_priv             | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Alter_priv             | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Show_db_priv           | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Super_priv             | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Create_tmp_table_priv  | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Lock_tables_priv       | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Execute_priv           | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Repl_slave_priv        | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Repl_client_priv       | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Create_view_priv       | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Show_view_priv         | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Create_routine_priv    | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Alter_routine_priv     | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Create_user_priv       | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Event_priv             | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Trigger_priv           | enum('N','Y')                     | NO   |     | N                     |       |\r\n| Create_tablespace_priv | enum('N','Y')                     | NO   |     | N                     |       |\r\n| ssl_type               | enum('','ANY','X509','SPECIFIED') | NO   |     |                       |       |\r\n| ssl_cipher             | blob                              | NO   |     | NULL                  |       |\r\n| x509_issuer            | blob                              | NO   |     | NULL                  |       |\r\n| x509_subject           | blob                              | NO   |     | NULL                  |       |\r\n| max_questions          | int(11) unsigned                  | NO   |     | 0                     |       |\r\n| max_updates            | int(11) unsigned                  | NO   |     | 0                     |       |\r\n| max_connections        | int(11) unsigned                  | NO   |     | 0                     |       |\r\n| max_user_connections   | int(11) unsigned                  | NO   |     | 0                     |       |\r\n| plugin                 | char(64)                          | YES  |     | mysql_native_password |       |\r\n| authentication_string  | text                              | YES  |     | NULL                  |       |\r\n| password_expired       | enum('N','Y')                     | NO   |     | N                     |       |\r\n+------------------------+-----------------------------------+------+-----+-----------------------+-------+\r\n43 rows in set (0.00 sec)\r\n<\/pre>\r\n\r\n\r\n\r\n<p>you can now combine this with the example given in Step 2. For example, if you want to return the list of users and their update privileges, you can run this command:<\/p>\r\n\r\n\r\n\r\n<pre class=\"wp-block-preformatted\">SELECT User, Update_priv FROM mysql.user;<\/pre>\r\n\r\n\r\n\r\n<p>Just replace &#8220;Update_priv&#8221; with any fields that you might need.<\/p>\r\n\r\n\r\n\r\n<h2 class=\"wp-block-heading\" id=\"h-show-information-about-current-user\"><span class=\"ez-toc-section\" id=\"Show-Information-About-Current-User\"><\/span>Show Information About Current User<span class=\"ez-toc-section-end\"><\/span><\/h2>\r\n\r\n\r\n\r\n<p>You can use a built-in function of MySQL to see the name and host of the user that you used to log into the MySQL command line. It&#8217;s the &#8220;user()&#8221; function, and all you have to do is select it:<\/p>\r\n\r\n\r\n\r\n<pre class=\"wp-block-preformatted\">SELECT user();<\/pre>\r\n\r\n\r\n\r\n<p>The output should give you information on the user running the query.<\/p>\r\n\r\n\r\n\r\n<p>And that&#8217;s it, with the completion of this tutorial, you have learned <strong>how to show MySQL user accounts via the command line.\u00a0<\/strong><\/p>\r\n\r\n\r\n<hr class=\"wp-block-separator\" \/>\r\n\r\n\r\n<div class=\"wp-block-image\">\r\n<figure class=\"alignright\"><img decoding=\"async\" width=\"200\" height=\"111\" class=\"wp-image-30957\" title=\"showing users in mysql\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/showing-users-in-mysql.jpg\" alt=\"showing users in mysql\" srcset=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/showing-users-in-mysql.jpg 200w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/showing-users-in-mysql-150x83.jpg 150w\" sizes=\"(max-width: 200px) 100vw, 200px\" \/><\/figure>\r\n<\/div>\r\n\r\n\r\n\r\n<p>If you have any additional questions on the MySQL database, feel free to leave a comment below. You can always get a <a href=\"https:\/\/www.rosehosting.com\/mysql-hosting.html\">Managed MySQL hosting<\/a> from us and our fully managed support will help you with problems related to MySQL or will explain <strong>how to show all users in the MySQL database.<\/strong><\/p>\r\n\r\n\r\n\r\n<p>PS. If you liked this post on making MySQL show all users, please share it with your friends via social media networks by using our share shortcuts. Thanks.<\/p>\r\n","protected":false},"excerpt":{"rendered":"<p>Today we are going to guide you on how to show all users in the MySQL users Database. A common &#8230; <\/p>\n<p class=\"read-more-container\"><a title=\"MySQL SHOW USERS: List All Users in a MySQL Database\" class=\"read-more button\" href=\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#more-19259\" aria-label=\"Read more about MySQL SHOW USERS: List All Users in a MySQL Database\">Read More<\/a><\/p>\n","protected":false},"author":4,"featured_media":30741,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1702,13],"tags":[1602,39,1601],"class_list":["post-19259","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-databases","category-tutorials","tag-list-all-users","tag-mysql","tag-show-all-users","generate-columns","tablet-grid-50","mobile-grid-100","grid-parent","grid-33"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.2 (Yoast SEO v27.2) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>MySQL SHOW USERS: List All Users in a MySQL Database<\/title>\n<meta name=\"description\" content=\"Not able to find the MySQL SHOW USERS command? In this guide, you will learn how to list\/show all users in a MySQL database server.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"MySQL SHOW USERS: List All Users in a MySQL Database\" \/>\n<meta property=\"og:description\" content=\"Not able to find the MySQL SHOW USERS command? In this guide, you will learn how to list\/show all users in a MySQL database server.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/\" \/>\n<meta property=\"og:site_name\" content=\"RoseHosting\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/RoseHosting\" \/>\n<meta property=\"article:author\" content=\"https:\/\/www.facebook.com\/rosehosting.helpdesk\" \/>\n<meta property=\"article:published_time\" content=\"2021-04-08T08:11:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2022-12-19T12:20:26+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/mysql-show-users-7.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"742\" \/>\n\t<meta property=\"og:image:height\" content=\"372\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Jeff Wilson\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:title\" content=\"MySQL SHOW USERS: List All Users in a MySQL Database\" \/>\n<meta name=\"twitter:description\" content=\"Not able to find the MySQL SHOW USERS command? In this guide, you will learn how to list\/show all users in a MySQL database server.\" \/>\n<meta name=\"twitter:creator\" content=\"@rosehosting\" \/>\n<meta name=\"twitter:site\" content=\"@rosehosting\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Jeff Wilson\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"8 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/\"},\"author\":{\"name\":\"Jeff Wilson\",\"@id\":\"https:\/\/www.rosehosting.com\/blog\/#\/schema\/person\/7ce77a842fa6a9a7f8efa186f2353713\"},\"headline\":\"MySQL SHOW USERS: List All Users in a MySQL Database\",\"datePublished\":\"2021-04-08T08:11:00+00:00\",\"dateModified\":\"2022-12-19T12:20:26+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/\"},\"wordCount\":866,\"commentCount\":3,\"publisher\":{\"@id\":\"https:\/\/www.rosehosting.com\/blog\/#organization\"},\"image\":{\"@id\":\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/mysql-show-users-7.jpg\",\"keywords\":[\"list all users\",\"mysql\",\"show all users\"],\"articleSection\":[\"Databases\",\"Tutorials\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/\",\"url\":\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/\",\"name\":\"MySQL SHOW USERS: List All Users in a MySQL Database\",\"isPartOf\":{\"@id\":\"https:\/\/www.rosehosting.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/mysql-show-users-7.jpg\",\"datePublished\":\"2021-04-08T08:11:00+00:00\",\"dateModified\":\"2022-12-19T12:20:26+00:00\",\"description\":\"Not able to find the MySQL SHOW USERS command? In this guide, you will learn how to list\/show all users in a MySQL database server.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#primaryimage\",\"url\":\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/mysql-show-users-7.jpg\",\"contentUrl\":\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/mysql-show-users-7.jpg\",\"width\":742,\"height\":372,\"caption\":\"MySQL Show Users\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.rosehosting.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"MySQL SHOW USERS: List All Users in a MySQL Database\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.rosehosting.com\/blog\/#website\",\"url\":\"https:\/\/www.rosehosting.com\/blog\/\",\"name\":\"RoseHosting.com\",\"description\":\"Premium Linux Tutorials Since 2001\",\"publisher\":{\"@id\":\"https:\/\/www.rosehosting.com\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.rosehosting.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.rosehosting.com\/blog\/#organization\",\"name\":\"RoseHosting\",\"url\":\"https:\/\/www.rosehosting.com\/blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.rosehosting.com\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/android-chrome-192x192-1.png\",\"contentUrl\":\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/android-chrome-192x192-1.png\",\"width\":192,\"height\":192,\"caption\":\"RoseHosting\"},\"image\":{\"@id\":\"https:\/\/www.rosehosting.com\/blog\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/RoseHosting\",\"https:\/\/x.com\/rosehosting\",\"https:\/\/www.linkedin.com\/in\/rosehosting\/\"],\"description\":\"RoseHosting is a leading Linux hosting provider, serving thousands of clients world-wide since 2001.\",\"email\":\"info@rosehosting.com\",\"telephone\":\"(314) 275-0414\",\"legalName\":\"Rose Web Services LLC\",\"foundingDate\":\"2001-04-02\",\"numberOfEmployees\":{\"@type\":\"QuantitativeValue\",\"minValue\":\"11\",\"maxValue\":\"50\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.rosehosting.com\/blog\/#\/schema\/person\/7ce77a842fa6a9a7f8efa186f2353713\",\"name\":\"Jeff Wilson\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/secure.gravatar.com\/avatar\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g\",\"caption\":\"Jeff Wilson\"},\"description\":\"An experienced Linux veteran with many years of experience. Helping other Linux admins with frequent Linux and business-related blog posts on the RoseHosting blog. Techie by choice. Loving nature and travel. Happily married and father of two lovely children.\",\"sameAs\":[\"https:\/\/www.rosehosting.com\",\"https:\/\/www.facebook.com\/rosehosting.helpdesk\"],\"url\":\"https:\/\/www.rosehosting.com\/blog\/author\/jwilson\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"MySQL SHOW USERS: List All Users in a MySQL Database","description":"Not able to find the MySQL SHOW USERS command? In this guide, you will learn how to list\/show all users in a MySQL database server.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/","og_locale":"en_US","og_type":"article","og_title":"MySQL SHOW USERS: List All Users in a MySQL Database","og_description":"Not able to find the MySQL SHOW USERS command? In this guide, you will learn how to list\/show all users in a MySQL database server.","og_url":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/","og_site_name":"RoseHosting","article_publisher":"https:\/\/www.facebook.com\/RoseHosting","article_author":"https:\/\/www.facebook.com\/rosehosting.helpdesk","article_published_time":"2021-04-08T08:11:00+00:00","article_modified_time":"2022-12-19T12:20:26+00:00","og_image":[{"width":742,"height":372,"url":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/mysql-show-users-7.jpg","type":"image\/jpeg"}],"author":"Jeff Wilson","twitter_card":"summary_large_image","twitter_title":"MySQL SHOW USERS: List All Users in a MySQL Database","twitter_description":"Not able to find the MySQL SHOW USERS command? In this guide, you will learn how to list\/show all users in a MySQL database server.","twitter_creator":"@rosehosting","twitter_site":"@rosehosting","twitter_misc":{"Written by":"Jeff Wilson","Est. reading time":"8 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#article","isPartOf":{"@id":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/"},"author":{"name":"Jeff Wilson","@id":"https:\/\/www.rosehosting.com\/blog\/#\/schema\/person\/7ce77a842fa6a9a7f8efa186f2353713"},"headline":"MySQL SHOW USERS: List All Users in a MySQL Database","datePublished":"2021-04-08T08:11:00+00:00","dateModified":"2022-12-19T12:20:26+00:00","mainEntityOfPage":{"@id":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/"},"wordCount":866,"commentCount":3,"publisher":{"@id":"https:\/\/www.rosehosting.com\/blog\/#organization"},"image":{"@id":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#primaryimage"},"thumbnailUrl":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/mysql-show-users-7.jpg","keywords":["list all users","mysql","show all users"],"articleSection":["Databases","Tutorials"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/","url":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/","name":"MySQL SHOW USERS: List All Users in a MySQL Database","isPartOf":{"@id":"https:\/\/www.rosehosting.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#primaryimage"},"image":{"@id":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#primaryimage"},"thumbnailUrl":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/mysql-show-users-7.jpg","datePublished":"2021-04-08T08:11:00+00:00","dateModified":"2022-12-19T12:20:26+00:00","description":"Not able to find the MySQL SHOW USERS command? In this guide, you will learn how to list\/show all users in a MySQL database server.","breadcrumb":{"@id":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#primaryimage","url":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/mysql-show-users-7.jpg","contentUrl":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2016\/05\/mysql-show-users-7.jpg","width":742,"height":372,"caption":"MySQL Show Users"},{"@type":"BreadcrumbList","@id":"https:\/\/www.rosehosting.com\/blog\/mysql-show-users\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.rosehosting.com\/blog\/"},{"@type":"ListItem","position":2,"name":"MySQL SHOW USERS: List All Users in a MySQL Database"}]},{"@type":"WebSite","@id":"https:\/\/www.rosehosting.com\/blog\/#website","url":"https:\/\/www.rosehosting.com\/blog\/","name":"RoseHosting.com","description":"Premium Linux Tutorials Since 2001","publisher":{"@id":"https:\/\/www.rosehosting.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.rosehosting.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.rosehosting.com\/blog\/#organization","name":"RoseHosting","url":"https:\/\/www.rosehosting.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.rosehosting.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/android-chrome-192x192-1.png","contentUrl":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/android-chrome-192x192-1.png","width":192,"height":192,"caption":"RoseHosting"},"image":{"@id":"https:\/\/www.rosehosting.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/RoseHosting","https:\/\/x.com\/rosehosting","https:\/\/www.linkedin.com\/in\/rosehosting\/"],"description":"RoseHosting is a leading Linux hosting provider, serving thousands of clients world-wide since 2001.","email":"info@rosehosting.com","telephone":"(314) 275-0414","legalName":"Rose Web Services LLC","foundingDate":"2001-04-02","numberOfEmployees":{"@type":"QuantitativeValue","minValue":"11","maxValue":"50"}},{"@type":"Person","@id":"https:\/\/www.rosehosting.com\/blog\/#\/schema\/person\/7ce77a842fa6a9a7f8efa186f2353713","name":"Jeff Wilson","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g","caption":"Jeff Wilson"},"description":"An experienced Linux veteran with many years of experience. Helping other Linux admins with frequent Linux and business-related blog posts on the RoseHosting blog. Techie by choice. Loving nature and travel. Happily married and father of two lovely children.","sameAs":["https:\/\/www.rosehosting.com","https:\/\/www.facebook.com\/rosehosting.helpdesk"],"url":"https:\/\/www.rosehosting.com\/blog\/author\/jwilson\/"}]}},"_links":{"self":[{"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/posts\/19259","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/comments?post=19259"}],"version-history":[{"count":23,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/posts\/19259\/revisions"}],"predecessor-version":[{"id":44399,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/posts\/19259\/revisions\/44399"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/media\/30741"}],"wp:attachment":[{"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/media?parent=19259"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/categories?post=19259"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/tags?post=19259"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}