On this page
FIND COLUMN
Finds the columns, and their tables, whose name contains the text you type, in the whole database.
Syntax
FIND COLUMN <text>
Arguments
| Argument | Required | Values | Default |
|---|---|---|---|
<text> | Yes | A column name or part of it; % matches any text | None |
Examples
FIND COLUMN COUNTRY_ID;
FIND COLUMN EMAIL;
Details
Matching
The text is searched inside column names, as typed: it is not converted to upper or lower case, so whether the search ignores case depends on the database. % matches any text and _ any single character. The search covers the whole database, not one schema or table: every column whose name contains the text is listed, with its table. The command fails when no text is given.
Older names
SHOW COLUMN, SH COL and SHCOL still work: they run the same command. FIND COLUMN is the recommended name, since the command finds tables by one of their column names. New scripts should use it.
Related
Used in these how-tos
- How do I explore an unfamiliar database in fifteen minutes?
- How do I check what depends on a table before I change it?
Last modified in release 5.5.0.
Found something wrong or unclear on this page? Tell us, with the page address.