Posts Tagged ‘mysql

One of the frustrating things with working with MySQL is of importing large sql dump files. Either you get a ‘max execution time exceeded’ error from PHP or a ‘Max_allowed_packet_size’ from MySQL. In a recent task I needed to import a table of around a million records on a remote host, which quickly became an [...]

A tedious task during web development is that of database schema creation. A schema containing a few tables comprising of a small set of rows is quick, while that containing dozens of tables and large numbers of columns is a tedious process. I usually resort to a small php script with some regular expression tossed [...]

Recently my favorite MySQL Swiss Army Knife has to be Toad for MySQL. Not only does it have a plethora of tools and interesting features, it is free. A few days back I’d to compare database schemas of different versions of a application to see if some table fields had changed between versions. Comparing a [...]

mysql administration program, adminer

easily copy tables in mysql

Whether desktop or web based, there has recently been a proliferation of SQL design tools on the net. SchemaBank may look like one more in the box. But a detailed look at the features will show you more on offer. SchemaBank is a visual data modelling tool which can help you create ERD diagrams within [...]

The MySQL SELECT is a ubiquitous statement. You can select rows using the ‘*’ operator or by listing the individual column names. But many times you may require using all the columns from a table except a couple of them. For example you may have a table containing twelve columns from which you require only [...]

HeidiSQL is an easy-to-use ide for web-developers using the popular MySQL-Database. It allows you to manage and browse your databases and tables from an intuitive Windows® interface. With a download size of less than 2Mb, it is quite lightweight and fast to load.

Below is a small script that lets you read the table sizes of a MySQL database. < ?php   $link = mysql_connect(’host’, ‘username’, ‘password’);   $db_name = "your database name here"; $tables = array();   mysql_select_db($db_name, $link); $result = mysql_query("SHOW TABLE STATUS");   while($row = mysql_fetch_array($result)) { /* We return the size in Kilobytes */ [...]