Install MyCLI to improve the SQL typing

Windows Articles

How to install PHP 8 on CentOS 8?

Hello, friends. This post will help you install PHP 8 on CentOS 8. The procedure is quite simple. PHP 8 has seen the light and...

PHP 8.0 available

PHP is one of the easiest open source programming languages to learn. Similarly, PHP is very popular and suitable for website development and can...

How to install PHP 8 on Ubuntu 20.04 / Debian 10?

Hello, friends. In this post, you will learn how to install PHP 8 on Ubuntu 20.04 / Debian 10. This way, you will be...

Learn how to control the volume of Windows using the mouse wheel.

Hi! Windows recently celebrated its 35th anniversary. Therefore, it is one of the longest lasting and most used systems currently. On the other hand,...

Install Nim programming language on Ubuntu 20.04 / Debian 10

Nowadays, almost everything is done with the help of a computer and a program. And the programs are made through a programming language. That...
angeloma
angeloma
Senior Writer and partner

If we are using MySQL or MariaDB it is because we know the commands and the sentences. However, many times, despite knowing them, we can make a mistake. And a mistake could result in a loss of time or great damage to our database. For this and other reasons is that usually, on the client side we use applications to help us with the task. And on the server side? Fortunately, on the server side, we have available a tool that will help us interact with MySQL or MariaDB. So today I will teach you how to install MyCLI to improve the SQL typing.

MyCLI is a tool made in Python with a BSD license that will help us to interact with the SQL language. It supports syntax highlighting and autocompletion. Currently, it only supports MySQL and MariaDB, more than enough for daily work. It has versions for Linux, Windows, and MacOS but it is in Linux where it is more focused.

So, let us install it.

Install MyCLI on Linux

MyCLI is easy to install on our Linux distribution because it is available through PIP. However, for some systems, it is found in the official repositories making installation even easier. So let us go for it.

If you are using Debian, Ubuntu, Linux Mint or ElementaryOS, open a terminal and run:

:~$ sudo apt install mycli

1 Install MyCLI
1 Install MyCLI

On the other hand, if you are using Fedora:

:~$ sudo dnf install mycli

However for others Linux distribution, you have to install python PIP and then,

:~$ pip install mycli

As you can see the installation is simple.

Basic use of MyCLI

Once we have it installed in our system, it only remains to start using it.

To use it, it is necessary to follow this syntax:

:~$ mycli -u [user] -p [database]

Then, you will have to type the root password to enter. It is also possible to do this by specifying a user and a host, for example:

:~$ mycli -u [user] -h [host] -p [database]

Once you have entered your password, you will see that you can start working. Its main feature is the autocompletion of the syntax.

2.- Using MyCLI
2.- Using MyCLI

Finally, MyCLI has the help that you can take full advantage of.

:~$ mycli --help

3.- MyCLI version
3.- MyCLI version

This way you will be able to use MyCLI better.

Conclusion

MyCLI is a very simple tool but it will help a lot in SQL management. Although it is limited to MySQL and MariaDB it is enough for our daily work or educational project. This greatly improves workflow and agility in SQL.

More articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest article

How to install PHP 8 on CentOS 8?

Hello, friends. This post will help you install PHP 8 on CentOS 8. The procedure is quite simple. PHP 8 has seen the light and...

PHP 8.0 available

PHP is one of the easiest open source programming languages to learn. Similarly, PHP is very popular and suitable for website development and can...

How to install PHP 8 on Ubuntu 20.04 / Debian 10?

Hello, friends. In this post, you will learn how to install PHP 8 on Ubuntu 20.04 / Debian 10. This way, you will be...

Learn how to control the volume of Windows using the mouse wheel.

Hi! Windows recently celebrated its 35th anniversary. Therefore, it is one of the longest lasting and most used systems currently. On the other hand,...

Install Nim programming language on Ubuntu 20.04 / Debian 10

Nowadays, almost everything is done with the help of a computer and a program. And the programs are made through a programming language. That...
x