- Trending Categories
- Data Structure
- Operating System
- C Programming
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How can I see how long statements take to execute on the MySQL command line?
For every single statement on MySQL command line, it shows the exact time to execute the specific statement.
Let us first create a table −
mysql> create table DemoTable1589 -> ( -> EmployeeId int, -> EmployeeName varchar(20) -> ); Query OK, 0 rows affected (0.56 sec)
Insert some records in the table using insert command −
mysql> insert into DemoTable1589 values(101,'Sam'); Query OK, 1 row affected (0.15 sec) mysql> insert into DemoTable1589 values(102,'Bob'); Query OK, 1 row affected (0.18 sec) mysql> insert into DemoTable1589 values(103,'David'); Query OK, 1 row affected (0.16 sec)
Display all records from the table using select statement −
mysql> select * from DemoTable1589;
This will produce the following output −
+------------+--------------+ | EmployeeId | EmployeeName | +------------+--------------+ | 101 | Sam | | 102 | Bob | | 103 | David | +------------+--------------+ 3 rows in set (0.04 sec)
- How to execute Python multi-line statements in the one-line at command-line?
- How to open MySQL command line on Windows10?
- How to see spaces in data when selecting with MySQL command line client?
- How can I see global locks in MySQL (innodb)?
- How to create a database on command line in MySQL?
- How can I see the description of a MySQL Temporary Tables?
- How can we return to windows command shell from MySQL command line tool?
- How to display the value of a variable on command line in MySQL?
- How to repair MySQL tables from the command line?
- Using Options on the Command Line for MySQL programs?
- The MySQL Command-Line Client
- How is it possible to enter multiple MySQL statements on a single line?
- How can I see the CREATE TABLE statement of an existing MySQL table?
- How to upgrade MySQL server from command line?