Search database name in information_schema database This is my sample data. I would like to find other database besides information_schema using only information from information_schema.
mysql&gt; SELECT * FROM TABLES LIMIT 2;
+---------------+--------------------+----------------+-------------+--------+---------+------------+------------+----------------+-------------+-----------------+--------------+-----------+----------------+-------------+-------------+------------+-----------------+----------+----------------+---------------+
| TABLE_CATALOG | TABLE_SCHEMA       | TABLE_NAME     | TABLE_TYPE  | ENGINE | VERSION | ROW_FORMAT | TABLE_ROWS | AVG_ROW_LENGTH | DATA_LENGTH | MAX_DATA_LENGTH | INDEX_LENGTH | DATA_FREE | AUTO_INCREMENT | CREATE_TIME | UPDATE_TIME | CHECK_TIME | TABLE_COLLATION | CHECKSUM | CREATE_OPTIONS | TABLE_COMMENT |
+---------------+--------------------+----------------+-------------+--------+---------+------------+------------+----------------+-------------+-----------------+--------------+-----------+----------------+-------------+-------------+------------+-----------------+----------+----------------+---------------+
| NULL          | information_schema | CHARACTER_SETS | SYSTEM VIEW | MEMORY |       0 | Fixed      |       NULL |            576 |           0 |        16661376 |            0 |         0 |           NULL | NULL        | NULL        | NULL       | utf8_general_ci |     NULL | max_rows=29127 |               | 
| NULL          | information_schema | COLLATIONS     | SYSTEM VIEW | MEMORY |       0 | Fixed      |       NULL |            423 |           0 |        16737264 |            0 |         0 |           NULL | NULL        | NULL        | NULL       | utf8_general_ci |     NULL | max_rows=39662 |               | 
+---------------+--------------------+----------------+-------------+--------+---------+------------+------------+----------------+-------------+-----------------+--------------+-----------+----------------+-------------+-------------+------------+-----------------+----------+----------------+---------------+
2 rows in set (0.06 sec)

mysql&gt; 

So, I use this syntax. What's wrong in this and how do I fix it?
mysql&gt; SELECT * FROM TABLES WHERE TABLE_SCHEMA NOT IN information_schema;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'information_schema' at line 1
mysql&gt;
information_schema in this context is a string value, not an object name, so you need to enclose it in quotes like so:
SELECT * 
FROM TABLES W
WHERE TABLE_SCHEMA NOT IN ('information_schema')