Related Articles
How to Get Size of a Database in Mysql
To Get Data Base Size in MB and Free Space in MBSELECT table_schema “dbName”, sum( data_length + index_length ) / 1024 / 1024 “Data Base Size in MB”, sum( data_free )/ 1024 / 1024 “Free Space in MB”FROM information_schema.TABLESGROUP BY table_schema ; To Get Size in GB: SELECT sum(round(((data_length + index_length) / 1024 […]
Command to see memory space on Linux in GB
Command to see Memory Space available in GB on Linux df -h How to start restart linux: just enter restart How to start Mysql on Centos Linux server: /etc/init.d/mysqld start Restart Mysql on Linux Centos: /etc/init.d/mysqld restart Stop Mysql on Linux Centos: /etc/init.d/mysqld stop Check status of Mysql on Linux Centos: /etc/init.d/mysqld status How to […]
Search and Retrieve Data from MySQL DB Using PHP
Below is the Simple PHP and MYSQL Search Program. Use below database queries: CREATE TABLE IF NOT EXISTS user (id int(10) NOT NULL AUTO_INCREMENT,Name varchar(20) NOT NULL,PRIMARY KEY (id)); INSERT INTO user (id, Name) VALUES (‘1’, ‘vicky’), (‘2’, ‘vivek’); Below is the sample program: