Giuseppe Maxia wrote:
> I have been answering questions for almost one year in a NG
> on MySQL (in Italian), and I can contribute some of the most
> common questions.
Your list is excellent Giuseppe. I assume Gary was interested in the
answers as well as the questions. :-)

I'll offer a few more questions and answers that I think are common.

1. Troubleshooting

- What version of MySQL I am running?

mysql> show variables like 'version';

- Where is the MySQL server error log file?

Often the error log is in the data directory, named <hostname>.err. But
the location is configurable, so check your my.cnf or my.ini files.

- Where is the MySQL data directory?

mysql> show variables like 'datadir';

The datadir may also be specified in the my.cnf or my.ini configuration
file, or on UNIX/Linux by the command-line option `--datadir' in the
safe_mysqld script or /etc/init.d/mysql script. You may also find the
options currently in use on UNIX/Linux by checking the mysqld process
listing with `ps'.

2. SQL

- How can I make my query faster?

In general, this varies on many factors, including table structure,
table storage engine, and SQL query. There is a lot of doentation on
MySQL performance tuning. Start here:

- What is the largest value I can store in a given datatype?

See the doentation for each datatype. Start here:

4. Migration

- How can I convert a Microsoft Excel spreadsheet to MySQL tables?

The easiest free solution is to save an Excel worksheet as a
comma-separated values (CSV) file, and then use MySQL's LOAD DATA INFILE
command to read in that textual data. See

5. Various

- Can I limit the size of a database?

MySQL has no built-in property to define and enforce a limit to the size
or number of records in a database or table. People have suggested
various methods to work around this.

Some solutions use a scheduled job to detect when a database has
exceeded the authorized space, and then raise it to the attention of the
system administrator. But this is only a reactive solution, and does
not enforce a size limit.

Some solutions try to use the operating system's quota enforcement
(where available), but this solution is complex and usually
insufficient, because MySQL databases are generally all owned by one
user id, and stored under one directory. So unless the quota
enforcement can be made per-directory or per-file, it's hard to use this
way. Also, InnoDB tables are all stored together in one physical file
by default.

Some solutions put the database files on separate filesystems, and
symbolically link them into MySQL's data directory. When the filesystem
fills up, further writes get fatal errors. But this is not a good
strategy for graceful error handling.

- When is MySQL version N going to be released?

No one on Usenet newsgroups can answer this for certain. In fact, MySQL
AB is not likely to answer this either. You'll just have to wait with
the rest of us for the software to be ready.

Unless you are comfortable using beta software, you should not depend on
features of any product that are not in a released version yet.

Bill K.