You can define a view in MySQL as follows:
CREATE VIEW v AS SELECT
'MySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQL';
The above long string might give trouble reading, but 'MySQLMy..'
is 70 characters long. It will work fine, but
check out how MySQL stores it (output of SHOW CREATE VIEW):
CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost`
SQL SECURITY DEFINER VIEW `v` AS select
'MySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQL'
AS `MySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQLMySQL`
This is where the trouble starts. If you backup
your schema using mysqldump, it will get the above definition,
but when you restore it, you'll get the following error:
ERROR 1166 (42000) at line …
[Read more]