List:Commits« Previous MessageNext Message »
From:mleich Date:October 5 2007 1:38pm
Subject:bk commit into 5.1 tree (mleich:1.2574) BUG#31237
View as plain text  
Below is the list of changes that have just been committed into a local
5.1 repository of mleich. When mleich does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html

ChangeSet@stripped, 2007-10-05 15:38:34+02:00, mleich@stripped +5 -0
  1. Fix for Bug#31237 Test "ndb_views" fails because of differing order of select results
  2. Cleanup of test

  mysql-test/suite/funcs_1/r/innodb_views.result@stripped, 2007-10-05 15:36:31+02:00, mleich@stripped +155 -105
    Updated expected results

  mysql-test/suite/funcs_1/r/memory_views.result@stripped, 2007-10-05 15:36:31+02:00, mleich@stripped +155 -105
    Updated expected results

  mysql-test/suite/funcs_1/r/myisam_views.result@stripped, 2007-10-05 15:36:32+02:00, mleich@stripped +9324 -8540
    Updated expected results

  mysql-test/suite/funcs_1/r/ndb_views.result@stripped, 2007-10-05 15:36:32+02:00, mleich@stripped +177 -127
    Updated expected results

  mysql-test/suite/funcs_1/views/views_master.inc@stripped, 2007-10-05 15:36:32+02:00, mleich@stripped +272 -273
    1. Fix for Bug#31237
       Typical changes:
       - Move LIMIT .... from CREATE VIEW statement to the SELECT checking the VIEW content
       - Partially refine the SELECT on the VIEW to get a reproducible result
    2. Cleanup of test
       - replace error numbers by names
       - remove comments and workarounds dedicated to now fixed bugs
       - minor fixes or improvements in comments

diff -Nrup a/mysql-test/suite/funcs_1/r/innodb_views.result b/mysql-test/suite/funcs_1/r/innodb_views.result
--- a/mysql-test/suite/funcs_1/r/innodb_views.result	2007-09-24 15:30:27 +02:00
+++ b/mysql-test/suite/funcs_1/r/innodb_views.result	2007-10-05 15:36:31 +02:00
@@ -169,6 +169,58 @@ insert into tb2 (f59,f60,f61) values (10
 INSERT INTO tb2 (f59,f60) VALUES( 299,899 );
 INSERT INTO tb2 (f59,f60) VALUES( 242,79  );
 INSERT INTO tb2 (f59,f60) VALUES( 424,89  );
+SELECT * FROM tb2 ORDER BY f59, f60, f61;
+f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
+1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
+2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
+3	3	0000000003	0000000000000000000000000000000000000000000000000000000000000003	0000000003	0000000000000000000000000000000000000000000000000000000000000003	-3	2.200000000000000000000000000000	3	2.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494348e-38	1.17549e-38	1.175494354e-38	01.17549e-38	00000001.175494354e-38	01.17549e-38	00000001.175494354e-38	1000-01-03	838:59:56	1970-01-04 00:00:03	1970-01-04 00:00:03	1904	1904	1904	2enum	1set
+4	4	0000000004	0000000000000000000000000000000000000000000000000000000000000004	0000000004	0000000000000000000000000000000000000000000000000000000000000004	-2	3.300000000000000000000000000000	4	3.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494347e-38	1.17549e-38	1.175494355e-38	01.17549e-38	00000001.175494355e-38	01.17549e-38	00000001.175494355e-38	1000-01-04	838:59:55	1970-01-05 00:00:04	1970-01-05 00:00:04	1905	1905	1905	1enum	2set
+4	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+5	5	0000000005	0000000000000000000000000000000000000000000000000000000000000005	0000000005	0000000000000000000000000000000000000000000000000000000000000005	-1	4.400000000000000000000000000000	5	4.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494346e-38	1.17549e-38	1.175494356e-38	01.17549e-38	00000001.175494356e-38	01.17549e-38	00000001.175494356e-38	1000-01-05	838:59:54	1970-01-06 00:00:05	1970-01-06 00:00:05	1906	1906	1906	2enum	1set,2set
+6	6	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0	5.500000000000000000000000000000	6	5.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494345e-38	1.17549e-38	1.175494357e-38	01.17549e-38	00000001.175494357e-38	01.17549e-38	00000001.175494357e-38	1000-01-06	838:59:53	1970-01-07 00:00:06	1970-01-07 00:00:06	1907	1907	1907	1enum	1set
+7	7	0000000007	0000000000000000000000000000000000000000000000000000000000000007	0000000007	0000000000000000000000000000000000000000000000000000000000000007	1	6.600000000000000000000000000000	7	6.600000000000000000000000000000	0000000007	000000000000000000000000000000006.600000000000000000000000000000	0000000007	000000000000000000000000000000006.600000000000000000000000000000	-1.175494344e-38	1.175494358e-38	00000001.175494358e-38	00000001.175494358e-38	-1.175494344e-38	1.175494358e-38	00000001.175494358e-38	00000001.175494358e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494344e-38	1.17549e-38	1.175494358e-38	01.17549e-38	00000001.175494358e-38	01.17549e-38	00000001.175494358e-38	1000-01-07	838:59:52	1970-01-08 00:00:07	1970-01-08 00:00:07	1908	1908	1908	2enum	2set
+8	8	0000000008	0000000000000000000000000000000000000000000000000000000000000008	0000000008	0000000000000000000000000000000000000000000000000000000000000008	2	7.700000000000000000000000000000	8	7.700000000000000000000000000000	0000000008	000000000000000000000000000000007.700000000000000000000000000000	0000000008	000000000000000000000000000000007.700000000000000000000000000000	-1.175494343e-38	1.175494359e-38	00000001.175494359e-38	00000001.175494359e-38	-1.175494343e-38	1.175494359e-38	00000001.175494359e-38	00000001.175494359e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494343e-38	1.17549e-38	1.175494359e-38	01.17549e-38	00000001.175494359e-38	01.17549e-38	00000001.175494359e-38	1000-01-08	838:59:51	1970-01-09 00:00:08	1970-01-09 00:00:08	1909	1909	1909	1enum	1set,2set
+9	9	0000000009	0000000000000000000000000000000000000000000000000000000000000009	0000000009	0000000000000000000000000000000000000000000000000000000000000009	3	8.800000000000000000000000000000	9	8.800000000000000000000000000000	0000000009	000000000000000000000000000000008.800000000000000000000000000000	0000000009	000000000000000000000000000000008.800000000000000000000000000000	-1.175494342e-38	1.17549436e-38	000000001.17549436e-38	000000001.17549436e-38	-1.175494342e-38	1.17549436e-38	000000001.17549436e-38	000000001.17549436e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494342e-38	1.17549e-38	1.17549436e-38	01.17549e-38	000000001.17549436e-38	01.17549e-38	000000001.17549436e-38	1000-01-09	838:59:50	1970-01-10 00:00:09	1970-01-10 00:00:09	1910	1910	1910	2enum	1set
+10	10	0000000010	0000000000000000000000000000000000000000000000000000000000000010	0000000010	0000000000000000000000000000000000000000000000000000000000000010	4	9.900000000000000000000000000000	10	9.900000000000000000000000000000	0000000010	000000000000000000000000000000009.900000000000000000000000000000	0000000010	000000000000000000000000000000009.900000000000000000000000000000	-1.175494341e-38	1.175494361e-38	00000001.175494361e-38	00000001.175494361e-38	-1.175494341e-38	1.175494361e-38	00000001.175494361e-38	00000001.175494361e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494341e-38	1.17549e-38	1.175494361e-38	01.17549e-38	00000001.175494361e-38	01.17549e-38	00000001.175494361e-38	1000-01-10	838:59:49	1970-01-11 00:00:10	1970-01-11 00:00:10	1911	1911	1911	1enum	2set
+15	87	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+17	15	0000000016	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+19	18	0000000014	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+22	93	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+24	51654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+27	25	0000000026	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+29	28	0000000024	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+34	41	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+94	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+107	105	0000000106	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+107	105	0000000106	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+109	108	0000000104	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+109	108	0000000104	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+195	87	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+207	205	0000000206	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+209	208	0000000204	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+242	79	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+250	87895654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+292	93	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+299	899	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+321	NULL	0000000765	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+323	14376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+340	9984376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+394	41	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+424	89	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+441	16546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+500	NULL	0000000900	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+500	NULL	0000000900	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+500	NULL	0000000900	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+660	876546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+987	41	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+2550	775654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+2760	985654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+3330	764376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+3410	996546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+7876	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+9112	NULL	0000008771	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+76710	226546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+569300	9114376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
 Use test;
 
 Testcase 3.3.1.1 
@@ -203,27 +255,27 @@ f59	f60	f61
 8	8	0000000008
 9	9	0000000009
 CREATE or REPLACE VIEW v1 AS select f59,f60,f61
-FROM test.tb2 limit 4,3;
-select * FROM v1 order by f59,f60,f61 limit 0,10;
+FROM test.tb2;
+select * FROM v1 order by f59,f60,f61 limit 4,3;
 f59	f60	f61
+4	74	NULL
 5	5	0000000005
 6	6	0000000006
-7	7	0000000007
 CREATE or REPLACE VIEW v1 AS select distinct f59
-FROM test.tb2 limit 4,3;
-select * FROM v1 order by f59 limit 0,10;
+FROM test.tb2;
+select * FROM v1 order by f59 limit 4,3;
 f59
 5
 6
 7
 ALTER VIEW v1 AS select f59
-FROM test.tb2 limit 6,2;
-select * FROM v1 order by f59 limit 0,10;
+FROM test.tb2;
+select * FROM v1 order by f59 limit 6,2;
 f59
+6
 7
-8
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 order by f59 limit 100;
+from tb2 order by f59;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -237,7 +289,7 @@ f59
 8
 9
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 order by f59 asc limit 100;
+from tb2 order by f59 asc;
 select * FROM v1 limit 0,10;
 f59
 1
@@ -251,7 +303,7 @@ f59
 8
 9
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 order by f59 desc limit 100;
+from tb2 order by f59 desc;
 select * FROM v1 limit 0,10;
 f59
 569300
@@ -265,7 +317,7 @@ f59
 987
 660
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 group by f59 limit 100;
+from tb2 group by f59;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -279,7 +331,7 @@ f59
 9
 10
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 group by f59 asc limit 100;
+from tb2 group by f59 asc;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -293,7 +345,7 @@ f59
 9
 10
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 group by f59 desc limit 100;
+from tb2 group by f59 desc;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -307,7 +359,7 @@ f59
 9
 10
 CREATE or REPLACE VIEW v1 AS (select f59 from tb2)
-union (select f59 from t1) limit 100;
+union (select f59 from t1);
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -495,8 +547,8 @@ DROP VIEW  v1;
 Testcase 3.3.1.3 + 3.1.1.4 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
-CREATE VIEW v1 or REPLACE AS Select * from tb2 my_table limit 50;
-ERROR 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 'or REPLACE AS Select * from tb2 my_table limit 50' at line 1
+CREATE VIEW v1 or REPLACE AS Select * from tb2 my_table;
+ERROR 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 'or REPLACE AS Select * from tb2 my_table' at line 1
 CREATE VIEW v1 WITH CASCADED CHECK OPTION AS Select *
 from tb2 my_table limit 50;
 ERROR 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 'WITH CASCADED CHECK OPTION AS Select *
@@ -505,8 +557,8 @@ CREATE VIEW v1 WITH LOCAL CHECK OPTION A
 from tb2 my_table limit 50;
 ERROR 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 'WITH LOCAL CHECK OPTION AS Select *
 from tb2 my_table limit 50' at line 1
-SELECT * FROM tb2 my_table CREATE VIEW As v1 limit 100 ;
-ERROR 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 'CREATE VIEW As v1 limit 100' at line 1
+SELECT * FROM tb2 my_table CREATE VIEW As v1;
+ERROR 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 'CREATE VIEW As v1' at line 1
 CREATE or REPLACE VIEW v1 Select f59, f60
 from test.tb2 my_table where f59 = 250 ;
 ERROR 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 'Select f59, f60
@@ -581,8 +633,8 @@ Union ALL (Select from f1 t1);
 ERROR 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 'from f59 tb2)
 Union ALL (Select from f1 t1)' at line 1
 CREATE or REPLACE view v1 as Select f59, f60
-from tb2 by order f59 limit 100 ;
-ERROR 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 'by order f59 limit 100' at line 2
+from tb2 by order f59;
+ERROR 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 'by order f59' at line 2
 CREATE or REPLACE view v1 as Select f59, f60
 from tb2 by group f59  ;
 ERROR 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 'by group f59' at line 2
@@ -590,12 +642,12 @@ ERROR 42000: You have an error in your S
 Testcase 3.3.1.5 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
-CREATE VIEW v1 SELECT * FROM tb2 limit 100 ;
-ERROR 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 'SELECT * FROM tb2 limit 100' at line 1
-CREATE v1 AS SELECT * FROM tb2 limit 100 ;
-ERROR 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 'v1 AS SELECT * FROM tb2 limit 100' at line 1
-VIEW v1 AS SELECT * FROM tb2 limit 100 ;
-ERROR 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 'VIEW v1 AS SELECT * FROM tb2 limit 100' at line 1
+CREATE VIEW v1 SELECT * FROM tb2;
+ERROR 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 'SELECT * FROM tb2' at line 1
+CREATE v1 AS SELECT * FROM tb2;
+ERROR 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 'v1 AS SELECT * FROM tb2' at line 1
+VIEW v1 AS SELECT * FROM tb2;
+ERROR 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 'VIEW v1 AS SELECT * FROM tb2' at line 1
 CREATE VIEW v1 AS SELECT 1;
 DROP VIEW v1;
 VIEW v1 AS SELECT 1;
@@ -613,45 +665,43 @@ Testcase 3.3.1.6 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
 CREATE or REPLACE                       VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = UNDEFINED VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = MERGE     VIEW v1
-as SELECT * from tb2 limit 100 ;
-Warnings:
-Warning	1354	View merge algorithm can't be used here for now (assumed undefined algorithm)
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE           = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 '= TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE ALGORITHM   TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE ALGORITHM =           VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE TEMPTABLE = ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'TEMPTABLE = ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE TEMPTABLE - ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'TEMPTABLE - ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE GARBAGE   = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'GARBAGE   = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE ALGORITHM = GARBAGE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'GARBAGE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 Drop view if exists v1 ;
 CREATE or REPLACE VIEW v1
 AS SELECT * from tb2 where f59 < 1;
@@ -677,7 +727,7 @@ ERROR 42000: You have an error in your S
 Testcase 3.3.1.7 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
-Create view test.v1 AS Select * from test.tb2 limit 100 ;
+Create view test.v1 AS Select * from test.tb2;
 Alter view test.v1 AS Select F59 from test. tb2 limit 100 ;
 Drop view test.v1 ;
 Create view v1 AS Select * from test.tb2 limit 100 ;
@@ -884,13 +934,13 @@ SELECT * FROM test.v1 order by f59,f60,f
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
-CREATE OR REPLACE VIEW test.v1 AS SELECT F59 FROM tb2 limit 10,100;
+CREATE OR REPLACE VIEW test.v1 AS SELECT F59 FROM tb2;
 SHOW CREATE VIEW test.v1;
 View	Create View	character_set_client	collation_connection
-v1	CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select `tb2`.`f59` AS `F59` from `tb2` limit 10,100	latin1	latin1_swedish_ci
-SELECT * FROM test.v1 order by F59;
+v1	CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select `tb2`.`f59` AS `F59` from `tb2`	latin1	latin1_swedish_ci
+SELECT * FROM test.v1 order by F59 limit 10,100;
 F59
-4
+10
 15
 17
 19
@@ -943,8 +993,8 @@ ERROR HY000: 'test.tb2' is not VIEW
 Testcase 3.3.1.15 
 --------------------------------------------------------------------------------
 Drop table if exists test.v1 ;
-CREATE OR REPLACE view test.v1 as select * from tb2 LIMIT 2;
-SELECT * FROM test.v1;
+CREATE OR REPLACE view test.v1 as select * from tb2;
+SELECT * FROM test.v1 ORDER BY f59,f60,f61 LIMIT 2;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
@@ -1080,8 +1130,8 @@ ERROR HY000: View's SELECT and view's fi
 Testcase 3.3.1.21 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1;
-CREATE VIEW test.v1( F59, F60 ) AS SELECT F59, F60 From tb2 LIMIT 2;
-SELECT * FROM test.v1 order by F59, F60 desc;
+CREATE VIEW test.v1( F59, F60 ) AS SELECT F59, F60 From tb2;
+SELECT * FROM test.v1 order by F59, F60 desc LIMIT 2;
 F59	F60
 1	1
 2	2
@@ -1090,17 +1140,17 @@ Drop view if exists test.v1 ;
 Testcase 3.3.1.22 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1;
-CREATE VIEW test.v1( product ) AS SELECT f59*f60 From tb2 LIMIT 2;
-SELECT * FROM test.v1;
+CREATE VIEW test.v1( product ) AS SELECT f59*f60 From tb2;
+SELECT * FROM test.v1 WHERE product IS NOT NULL ORDER BY product LIMIT 2;
 product
 1
 4
 CREATE OR REPLACE VIEW test.v1( product ) AS SELECT 1*2;
-SELECT * FROM test.v1;
+SELECT * FROM test.v1 LIMIT 2;
 product
 2
 CREATE OR REPLACE VIEW test.v1( product ) AS SELECT USER();
-SELECT * FROM test.v1;
+SELECT * FROM test.v1 LIMIT 2;
 product
 root@localhost
 Drop view if exists test.v1 ;
@@ -1177,8 +1227,8 @@ DROP TEMPORARY TABLE t2;
 Testcase 3.3.1.26 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1;
-Create view test.v1 AS Select * from test.tb2 limit 2 ;
-Select * from test.v1;
+Create view test.v1 AS Select * from test.tb2;
+Select * from test.v1 order by f59, f60, f61 limit 2;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
@@ -1188,9 +1238,9 @@ Testcase 3.3.1.27 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS test.v1;
 Drop VIEW  IF EXISTS test.v1_1 ;
-Create view test.v1 AS Select * from test.tb2 limit 2 ;
+Create view test.v1 AS Select * from test.tb2;
 Create view test.v1_1 AS Select F59 from test.v1 ;
-Select * from test.v1_1 order by F59 limit 20 ;
+Select * from test.v1_1 order by F59 limit 2;
 F59
 1
 2
@@ -1737,29 +1787,29 @@ Drop view  if exists test.v1 ;
 Drop view  if exists test.v1_main;
 Drop view  if exists test1.v1_1 ;
 Drop database if exists test3 ;
-Create view test.v1 as Select f59, f60 FROM test.tb2 limit 20 ;
-Select * from test.v1 order by f59,f60;
+Create view test.v1 as Select f59, f60 FROM test.tb2;
+Select * from test.v1 order by f59,f60 limit 20;
 f59	f60
 1	1
 2	2
 3	3
 4	4
+4	74
 5	5
 6	6
 7	7
 8	8
 9	9
 10	10
-250	87895654
-340	9984376
-441	16546
-660	876546
-2550	775654
-2760	985654
-3330	764376
-3410	996546
-76710	226546
-569300	9114376
+15	87
+17	15
+19	18
+22	93
+24	51654
+27	25
+29	28
+34	41
+94	74
 Create table test1.t1 (f59 int,f60 int)  ;
 Insert into test1.t1 values (199,507) ;
 Create view test1.v1_1 as Select f59,f60 from test1.t1 ;
@@ -9670,17 +9720,17 @@ DROP TABLE t1_results;
 Testcase 3.3.1.50 - 3.3.1.53
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS test.v1;
-CREATE VIEW test.v1 AS SELECT * FROM test.tb2 limit 5 ;
-SELECT * FROM test.v1 order by f59 ;
+CREATE VIEW test.v1 AS SELECT * FROM test.tb2;
+SELECT * FROM test.v1 order by f59 limit 5;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
 3	3	0000000003	0000000000000000000000000000000000000000000000000000000000000003	0000000003	0000000000000000000000000000000000000000000000000000000000000003	-3	2.200000000000000000000000000000	3	2.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494348e-38	1.17549e-38	1.175494354e-38	01.17549e-38	00000001.175494354e-38	01.17549e-38	00000001.175494354e-38	1000-01-03	838:59:56	1970-01-04 00:00:03	1970-01-04 00:00:03	1904	1904	1904	2enum	1set
 5	5	0000000005	0000000000000000000000000000000000000000000000000000000000000005	0000000005	0000000000000000000000000000000000000000000000000000000000000005	-1	4.400000000000000000000000000000	5	4.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494346e-38	1.17549e-38	1.175494356e-38	01.17549e-38	00000001.175494356e-38	01.17549e-38	00000001.175494356e-38	1000-01-05	838:59:54	1970-01-06 00:00:05	1970-01-06 00:00:05	1906	1906	1906	2enum	1set,2set
-100	4	0000000004	0000000000000000000000000000000000000000000000000000000000000004	0000000004	0000000000000000000000000000000000000000000000000000000000000004	-2	3.300000000000000000000000000000	4	3.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494347e-38	1.17549e-38	1.175494355e-38	01.17549e-38	00000001.175494355e-38	01.17549e-38	00000001.175494355e-38	1000-01-04	838:59:55	1970-01-05 00:00:04	1970-01-05 00:00:04	1905	1905	1905	1enum	2set
+6	6	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0	5.500000000000000000000000000000	6	5.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494345e-38	1.17549e-38	1.175494357e-38	01.17549e-38	00000001.175494357e-38	01.17549e-38	00000001.175494357e-38	1000-01-06	838:59:53	1970-01-07 00:00:06	1970-01-07 00:00:06	1907	1907	1907	1enum	1set
 drop view test.v1 ;
-CREATE VIEW test.v1 AS SELECT F59,F61 FROM test.tb2 limit 50 ;
-SELECT * FROM test.v1 order by F59, F61 ;
+CREATE VIEW test.v1 AS SELECT F59,F61 FROM test.tb2;
+SELECT * FROM test.v1 order by F59, F61 limit 50;
 F59	F61
 1	0000000001
 2	0000000002
@@ -9733,8 +9783,8 @@ F59	F61
 76710	NULL
 569300	NULL
 drop view test.v1 ;
-CREATE VIEW test.v1 AS SELECT * FROM test.tb2 order by f59, f60, f61 limit 20 ;
-SELECT * FROM test.v1 order by f59,f60,f61 ;
+CREATE VIEW test.v1 AS SELECT * FROM test.tb2 order by f59, f60, f61;
+SELECT * FROM test.v1 order by f59,f60,f61 limit 20;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
@@ -9757,8 +9807,8 @@ f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	
 100	4	0000000004	0000000000000000000000000000000000000000000000000000000000000004	0000000004	0000000000000000000000000000000000000000000000000000000000000004	-2	3.300000000000000000000000000000	4	3.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494347e-38	1.17549e-38	1.175494355e-38	01.17549e-38	00000001.175494355e-38	01.17549e-38	00000001.175494355e-38	1000-01-04	838:59:55	1970-01-05 00:00:04	1970-01-05 00:00:04	1905	1905	1905	1enum	2set
 100	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
 drop view test.v1 ;
-CREATE VIEW test.v1 AS SELECT F59,f61 FROM test.tb2 limit 20 ;
-SELECT * FROM test.v1 order by f59,f61 desc limit 50;
+CREATE VIEW test.v1 AS SELECT F59,f61 FROM test.tb2;
+SELECT * FROM test.v1 order by f59,f61 desc limit 20;
 F59	f61
 1	0000000001
 2	0000000002
@@ -9769,17 +9819,17 @@ F59	f61
 8	0000000008
 9	0000000009
 10	0000000010
+15	NULL
+17	0000000016
+19	0000000014
+22	NULL
+24	NULL
+27	0000000026
+29	0000000024
+34	NULL
+94	NULL
 100	0000000004
-250	NULL
-340	NULL
-441	NULL
-660	NULL
-2550	NULL
-2760	NULL
-3330	NULL
-3410	NULL
-76710	NULL
-569300	NULL
+100	NULL
 drop view test.v1 ;
 
 Testcase 3.3.1.54 
@@ -10883,7 +10933,7 @@ CREATE ALGORITHM = TEMPTABLE VIEW v1 (f6
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10891,7 +10941,7 @@ CREATE VIEW v1 AS SELECT f59 AS f61 FROM
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10899,7 +10949,7 @@ CREATE VIEW v1 AS SELECT f61 FROM v2;
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10907,7 +10957,7 @@ CREATE VIEW v1 AS SELECT (SELECT f60 FRO
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10915,7 +10965,7 @@ CREATE VIEW v1 AS SELECT f61 FROM t1 HAV
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10923,7 +10973,7 @@ CREATE VIEW v1 AS SELECT f61 FROM t1 GRO
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10931,7 +10981,7 @@ CREATE VIEW v1 AS SELECT SUM(f59) AS f61
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10939,7 +10989,7 @@ CREATE VIEW v1 AS SELECT DISTINCTROW(f61
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10947,7 +10997,7 @@ CREATE VIEW v1 AS SELECT DISTINCT(f61)  
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
diff -Nrup a/mysql-test/suite/funcs_1/r/memory_views.result b/mysql-test/suite/funcs_1/r/memory_views.result
--- a/mysql-test/suite/funcs_1/r/memory_views.result	2007-09-24 15:30:27 +02:00
+++ b/mysql-test/suite/funcs_1/r/memory_views.result	2007-10-05 15:36:31 +02:00
@@ -173,6 +173,58 @@ insert into tb2 (f59,f60,f61) values (10
 INSERT INTO tb2 (f59,f60) VALUES( 299,899 );
 INSERT INTO tb2 (f59,f60) VALUES( 242,79  );
 INSERT INTO tb2 (f59,f60) VALUES( 424,89  );
+SELECT * FROM tb2 ORDER BY f59, f60, f61;
+f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
+1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
+2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
+3	3	0000000003	0000000000000000000000000000000000000000000000000000000000000003	0000000003	0000000000000000000000000000000000000000000000000000000000000003	-3	2.200000000000000000000000000000	3	2.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494348e-38	1.17549e-38	1.175494354e-38	01.17549e-38	00000001.175494354e-38	01.17549e-38	00000001.175494354e-38	1000-01-03	838:59:56	1970-01-04 00:00:03	1970-01-04 00:00:03	1904	1904	1904	2enum	1set
+4	4	0000000004	0000000000000000000000000000000000000000000000000000000000000004	0000000004	0000000000000000000000000000000000000000000000000000000000000004	-2	3.300000000000000000000000000000	4	3.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494347e-38	1.17549e-38	1.175494355e-38	01.17549e-38	00000001.175494355e-38	01.17549e-38	00000001.175494355e-38	1000-01-04	838:59:55	1970-01-05 00:00:04	1970-01-05 00:00:04	1905	1905	1905	1enum	2set
+4	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+5	5	0000000005	0000000000000000000000000000000000000000000000000000000000000005	0000000005	0000000000000000000000000000000000000000000000000000000000000005	-1	4.400000000000000000000000000000	5	4.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494346e-38	1.17549e-38	1.175494356e-38	01.17549e-38	00000001.175494356e-38	01.17549e-38	00000001.175494356e-38	1000-01-05	838:59:54	1970-01-06 00:00:05	1970-01-06 00:00:05	1906	1906	1906	2enum	1set,2set
+6	6	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0	5.500000000000000000000000000000	6	5.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494345e-38	1.17549e-38	1.175494357e-38	01.17549e-38	00000001.175494357e-38	01.17549e-38	00000001.175494357e-38	1000-01-06	838:59:53	1970-01-07 00:00:06	1970-01-07 00:00:06	1907	1907	1907	1enum	1set
+7	7	0000000007	0000000000000000000000000000000000000000000000000000000000000007	0000000007	0000000000000000000000000000000000000000000000000000000000000007	1	6.600000000000000000000000000000	7	6.600000000000000000000000000000	0000000007	000000000000000000000000000000006.600000000000000000000000000000	0000000007	000000000000000000000000000000006.600000000000000000000000000000	-1.175494344e-38	1.175494358e-38	00000001.175494358e-38	00000001.175494358e-38	-1.175494344e-38	1.175494358e-38	00000001.175494358e-38	00000001.175494358e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494344e-38	1.17549e-38	1.175494358e-38	01.17549e-38	00000001.175494358e-38	01.17549e-38	00000001.175494358e-38	1000-01-07	838:59:52	1970-01-08 00:00:07	1970-01-08 00:00:07	1908	1908	1908	2enum	2set
+8	8	0000000008	0000000000000000000000000000000000000000000000000000000000000008	0000000008	0000000000000000000000000000000000000000000000000000000000000008	2	7.700000000000000000000000000000	8	7.700000000000000000000000000000	0000000008	000000000000000000000000000000007.700000000000000000000000000000	0000000008	000000000000000000000000000000007.700000000000000000000000000000	-1.175494343e-38	1.175494359e-38	00000001.175494359e-38	00000001.175494359e-38	-1.175494343e-38	1.175494359e-38	00000001.175494359e-38	00000001.175494359e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494343e-38	1.17549e-38	1.175494359e-38	01.17549e-38	00000001.175494359e-38	01.17549e-38	00000001.175494359e-38	1000-01-08	838:59:51	1970-01-09 00:00:08	1970-01-09 00:00:08	1909	1909	1909	1enum	1set,2set
+9	9	0000000009	0000000000000000000000000000000000000000000000000000000000000009	0000000009	0000000000000000000000000000000000000000000000000000000000000009	3	8.800000000000000000000000000000	9	8.800000000000000000000000000000	0000000009	000000000000000000000000000000008.800000000000000000000000000000	0000000009	000000000000000000000000000000008.800000000000000000000000000000	-1.175494342e-38	1.17549436e-38	000000001.17549436e-38	000000001.17549436e-38	-1.175494342e-38	1.17549436e-38	000000001.17549436e-38	000000001.17549436e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494342e-38	1.17549e-38	1.17549436e-38	01.17549e-38	000000001.17549436e-38	01.17549e-38	000000001.17549436e-38	1000-01-09	838:59:50	1970-01-10 00:00:09	1970-01-10 00:00:09	1910	1910	1910	2enum	1set
+10	10	0000000010	0000000000000000000000000000000000000000000000000000000000000010	0000000010	0000000000000000000000000000000000000000000000000000000000000010	4	9.900000000000000000000000000000	10	9.900000000000000000000000000000	0000000010	000000000000000000000000000000009.900000000000000000000000000000	0000000010	000000000000000000000000000000009.900000000000000000000000000000	-1.175494341e-38	1.175494361e-38	00000001.175494361e-38	00000001.175494361e-38	-1.175494341e-38	1.175494361e-38	00000001.175494361e-38	00000001.175494361e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494341e-38	1.17549e-38	1.175494361e-38	01.17549e-38	00000001.175494361e-38	01.17549e-38	00000001.175494361e-38	1000-01-10	838:59:49	1970-01-11 00:00:10	1970-01-11 00:00:10	1911	1911	1911	1enum	2set
+15	87	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+17	15	0000000016	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+19	18	0000000014	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+22	93	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+24	51654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+27	25	0000000026	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+29	28	0000000024	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+34	41	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+94	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+107	105	0000000106	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+107	105	0000000106	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+109	108	0000000104	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+109	108	0000000104	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+195	87	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+207	205	0000000206	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+209	208	0000000204	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+242	79	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+250	87895654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+292	93	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+299	899	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+321	NULL	0000000765	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+323	14376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+340	9984376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+394	41	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+424	89	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+441	16546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+500	NULL	0000000900	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+500	NULL	0000000900	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+500	NULL	0000000900	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+660	876546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+987	41	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+2550	775654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+2760	985654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+3330	764376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+3410	996546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+7876	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+9112	NULL	0000008771	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+76710	226546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+569300	9114376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
 Use test;
 
 Testcase 3.3.1.1 
@@ -207,27 +259,27 @@ f59	f60	f61
 8	8	0000000008
 9	9	0000000009
 CREATE or REPLACE VIEW v1 AS select f59,f60,f61
-FROM test.tb2 limit 4,3;
-select * FROM v1 order by f59,f60,f61 limit 0,10;
+FROM test.tb2;
+select * FROM v1 order by f59,f60,f61 limit 4,3;
 f59	f60	f61
+4	74	NULL
 5	5	0000000005
 6	6	0000000006
-7	7	0000000007
 CREATE or REPLACE VIEW v1 AS select distinct f59
-FROM test.tb2 limit 4,3;
-select * FROM v1 order by f59 limit 0,10;
+FROM test.tb2;
+select * FROM v1 order by f59 limit 4,3;
 f59
 5
 6
 7
 ALTER VIEW v1 AS select f59
-FROM test.tb2 limit 6,2;
-select * FROM v1 order by f59 limit 0,10;
+FROM test.tb2;
+select * FROM v1 order by f59 limit 6,2;
 f59
+6
 7
-8
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 order by f59 limit 100;
+from tb2 order by f59;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -241,7 +293,7 @@ f59
 8
 9
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 order by f59 asc limit 100;
+from tb2 order by f59 asc;
 select * FROM v1 limit 0,10;
 f59
 1
@@ -255,7 +307,7 @@ f59
 8
 9
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 order by f59 desc limit 100;
+from tb2 order by f59 desc;
 select * FROM v1 limit 0,10;
 f59
 569300
@@ -269,7 +321,7 @@ f59
 987
 660
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 group by f59 limit 100;
+from tb2 group by f59;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -283,7 +335,7 @@ f59
 9
 10
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 group by f59 asc limit 100;
+from tb2 group by f59 asc;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -297,7 +349,7 @@ f59
 9
 10
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 group by f59 desc limit 100;
+from tb2 group by f59 desc;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -311,7 +363,7 @@ f59
 9
 10
 CREATE or REPLACE VIEW v1 AS (select f59 from tb2)
-union (select f59 from t1) limit 100;
+union (select f59 from t1);
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -499,8 +551,8 @@ DROP VIEW  v1;
 Testcase 3.3.1.3 + 3.1.1.4 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
-CREATE VIEW v1 or REPLACE AS Select * from tb2 my_table limit 50;
-ERROR 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 'or REPLACE AS Select * from tb2 my_table limit 50' at line 1
+CREATE VIEW v1 or REPLACE AS Select * from tb2 my_table;
+ERROR 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 'or REPLACE AS Select * from tb2 my_table' at line 1
 CREATE VIEW v1 WITH CASCADED CHECK OPTION AS Select *
 from tb2 my_table limit 50;
 ERROR 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 'WITH CASCADED CHECK OPTION AS Select *
@@ -509,8 +561,8 @@ CREATE VIEW v1 WITH LOCAL CHECK OPTION A
 from tb2 my_table limit 50;
 ERROR 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 'WITH LOCAL CHECK OPTION AS Select *
 from tb2 my_table limit 50' at line 1
-SELECT * FROM tb2 my_table CREATE VIEW As v1 limit 100 ;
-ERROR 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 'CREATE VIEW As v1 limit 100' at line 1
+SELECT * FROM tb2 my_table CREATE VIEW As v1;
+ERROR 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 'CREATE VIEW As v1' at line 1
 CREATE or REPLACE VIEW v1 Select f59, f60
 from test.tb2 my_table where f59 = 250 ;
 ERROR 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 'Select f59, f60
@@ -585,8 +637,8 @@ Union ALL (Select from f1 t1);
 ERROR 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 'from f59 tb2)
 Union ALL (Select from f1 t1)' at line 1
 CREATE or REPLACE view v1 as Select f59, f60
-from tb2 by order f59 limit 100 ;
-ERROR 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 'by order f59 limit 100' at line 2
+from tb2 by order f59;
+ERROR 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 'by order f59' at line 2
 CREATE or REPLACE view v1 as Select f59, f60
 from tb2 by group f59  ;
 ERROR 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 'by group f59' at line 2
@@ -594,12 +646,12 @@ ERROR 42000: You have an error in your S
 Testcase 3.3.1.5 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
-CREATE VIEW v1 SELECT * FROM tb2 limit 100 ;
-ERROR 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 'SELECT * FROM tb2 limit 100' at line 1
-CREATE v1 AS SELECT * FROM tb2 limit 100 ;
-ERROR 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 'v1 AS SELECT * FROM tb2 limit 100' at line 1
-VIEW v1 AS SELECT * FROM tb2 limit 100 ;
-ERROR 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 'VIEW v1 AS SELECT * FROM tb2 limit 100' at line 1
+CREATE VIEW v1 SELECT * FROM tb2;
+ERROR 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 'SELECT * FROM tb2' at line 1
+CREATE v1 AS SELECT * FROM tb2;
+ERROR 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 'v1 AS SELECT * FROM tb2' at line 1
+VIEW v1 AS SELECT * FROM tb2;
+ERROR 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 'VIEW v1 AS SELECT * FROM tb2' at line 1
 CREATE VIEW v1 AS SELECT 1;
 DROP VIEW v1;
 VIEW v1 AS SELECT 1;
@@ -617,45 +669,43 @@ Testcase 3.3.1.6 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
 CREATE or REPLACE                       VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = UNDEFINED VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = MERGE     VIEW v1
-as SELECT * from tb2 limit 100 ;
-Warnings:
-Warning	1354	View merge algorithm can't be used here for now (assumed undefined algorithm)
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE           = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 '= TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE ALGORITHM   TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE ALGORITHM =           VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE TEMPTABLE = ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'TEMPTABLE = ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE TEMPTABLE - ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'TEMPTABLE - ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE GARBAGE   = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'GARBAGE   = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE ALGORITHM = GARBAGE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'GARBAGE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 Drop view if exists v1 ;
 CREATE or REPLACE VIEW v1
 AS SELECT * from tb2 where f59 < 1;
@@ -681,7 +731,7 @@ ERROR 42000: You have an error in your S
 Testcase 3.3.1.7 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
-Create view test.v1 AS Select * from test.tb2 limit 100 ;
+Create view test.v1 AS Select * from test.tb2;
 Alter view test.v1 AS Select F59 from test. tb2 limit 100 ;
 Drop view test.v1 ;
 Create view v1 AS Select * from test.tb2 limit 100 ;
@@ -888,13 +938,13 @@ SELECT * FROM test.v1 order by f59,f60,f
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
-CREATE OR REPLACE VIEW test.v1 AS SELECT F59 FROM tb2 limit 10,100;
+CREATE OR REPLACE VIEW test.v1 AS SELECT F59 FROM tb2;
 SHOW CREATE VIEW test.v1;
 View	Create View	character_set_client	collation_connection
-v1	CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select `tb2`.`f59` AS `F59` from `tb2` limit 10,100	latin1	latin1_swedish_ci
-SELECT * FROM test.v1 order by F59;
+v1	CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select `tb2`.`f59` AS `F59` from `tb2`	latin1	latin1_swedish_ci
+SELECT * FROM test.v1 order by F59 limit 10,100;
 F59
-4
+10
 15
 17
 19
@@ -947,8 +997,8 @@ ERROR HY000: 'test.tb2' is not VIEW
 Testcase 3.3.1.15 
 --------------------------------------------------------------------------------
 Drop table if exists test.v1 ;
-CREATE OR REPLACE view test.v1 as select * from tb2 LIMIT 2;
-SELECT * FROM test.v1;
+CREATE OR REPLACE view test.v1 as select * from tb2;
+SELECT * FROM test.v1 ORDER BY f59,f60,f61 LIMIT 2;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
@@ -1084,8 +1134,8 @@ ERROR HY000: View's SELECT and view's fi
 Testcase 3.3.1.21 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1;
-CREATE VIEW test.v1( F59, F60 ) AS SELECT F59, F60 From tb2 LIMIT 2;
-SELECT * FROM test.v1 order by F59, F60 desc;
+CREATE VIEW test.v1( F59, F60 ) AS SELECT F59, F60 From tb2;
+SELECT * FROM test.v1 order by F59, F60 desc LIMIT 2;
 F59	F60
 1	1
 2	2
@@ -1094,17 +1144,17 @@ Drop view if exists test.v1 ;
 Testcase 3.3.1.22 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1;
-CREATE VIEW test.v1( product ) AS SELECT f59*f60 From tb2 LIMIT 2;
-SELECT * FROM test.v1;
+CREATE VIEW test.v1( product ) AS SELECT f59*f60 From tb2;
+SELECT * FROM test.v1 WHERE product IS NOT NULL ORDER BY product LIMIT 2;
 product
 1
 4
 CREATE OR REPLACE VIEW test.v1( product ) AS SELECT 1*2;
-SELECT * FROM test.v1;
+SELECT * FROM test.v1 LIMIT 2;
 product
 2
 CREATE OR REPLACE VIEW test.v1( product ) AS SELECT USER();
-SELECT * FROM test.v1;
+SELECT * FROM test.v1 LIMIT 2;
 product
 root@localhost
 Drop view if exists test.v1 ;
@@ -1181,8 +1231,8 @@ DROP TEMPORARY TABLE t2;
 Testcase 3.3.1.26 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1;
-Create view test.v1 AS Select * from test.tb2 limit 2 ;
-Select * from test.v1;
+Create view test.v1 AS Select * from test.tb2;
+Select * from test.v1 order by f59, f60, f61 limit 2;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
@@ -1192,9 +1242,9 @@ Testcase 3.3.1.27 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS test.v1;
 Drop VIEW  IF EXISTS test.v1_1 ;
-Create view test.v1 AS Select * from test.tb2 limit 2 ;
+Create view test.v1 AS Select * from test.tb2;
 Create view test.v1_1 AS Select F59 from test.v1 ;
-Select * from test.v1_1 order by F59 limit 20 ;
+Select * from test.v1_1 order by F59 limit 2;
 F59
 1
 2
@@ -1741,29 +1791,29 @@ Drop view  if exists test.v1 ;
 Drop view  if exists test.v1_main;
 Drop view  if exists test1.v1_1 ;
 Drop database if exists test3 ;
-Create view test.v1 as Select f59, f60 FROM test.tb2 limit 20 ;
-Select * from test.v1 order by f59,f60;
+Create view test.v1 as Select f59, f60 FROM test.tb2;
+Select * from test.v1 order by f59,f60 limit 20;
 f59	f60
 1	1
 2	2
 3	3
 4	4
+4	74
 5	5
 6	6
 7	7
 8	8
 9	9
 10	10
-250	87895654
-340	9984376
-441	16546
-660	876546
-2550	775654
-2760	985654
-3330	764376
-3410	996546
-76710	226546
-569300	9114376
+15	87
+17	15
+19	18
+22	93
+24	51654
+27	25
+29	28
+34	41
+94	74
 Create table test1.t1 (f59 int,f60 int)  ;
 Insert into test1.t1 values (199,507) ;
 Create view test1.v1_1 as Select f59,f60 from test1.t1 ;
@@ -9675,17 +9725,17 @@ DROP TABLE t1_results;
 Testcase 3.3.1.50 - 3.3.1.53
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS test.v1;
-CREATE VIEW test.v1 AS SELECT * FROM test.tb2 limit 5 ;
-SELECT * FROM test.v1 order by f59 ;
+CREATE VIEW test.v1 AS SELECT * FROM test.tb2;
+SELECT * FROM test.v1 order by f59 limit 5;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
 3	3	0000000003	0000000000000000000000000000000000000000000000000000000000000003	0000000003	0000000000000000000000000000000000000000000000000000000000000003	-3	2.200000000000000000000000000000	3	2.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494348e-38	1.17549e-38	1.175494354e-38	01.17549e-38	00000001.175494354e-38	01.17549e-38	00000001.175494354e-38	1000-01-03	838:59:56	1970-01-04 00:00:03	1970-01-04 00:00:03	1904	1904	1904	2enum	1set
 5	5	0000000005	0000000000000000000000000000000000000000000000000000000000000005	0000000005	0000000000000000000000000000000000000000000000000000000000000005	-1	4.400000000000000000000000000000	5	4.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494346e-38	1.17549e-38	1.175494356e-38	01.17549e-38	00000001.175494356e-38	01.17549e-38	00000001.175494356e-38	1000-01-05	838:59:54	1970-01-06 00:00:05	1970-01-06 00:00:05	1906	1906	1906	2enum	1set,2set
-100	4	0000000004	0000000000000000000000000000000000000000000000000000000000000004	0000000004	0000000000000000000000000000000000000000000000000000000000000004	-2	3.300000000000000000000000000000	4	3.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494347e-38	1.17549e-38	1.175494355e-38	01.17549e-38	00000001.175494355e-38	01.17549e-38	00000001.175494355e-38	1000-01-04	838:59:55	1970-01-05 00:00:04	1970-01-05 00:00:04	1905	1905	1905	1enum	2set
+6	6	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0	5.500000000000000000000000000000	6	5.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494345e-38	1.17549e-38	1.175494357e-38	01.17549e-38	00000001.175494357e-38	01.17549e-38	00000001.175494357e-38	1000-01-06	838:59:53	1970-01-07 00:00:06	1970-01-07 00:00:06	1907	1907	1907	1enum	1set
 drop view test.v1 ;
-CREATE VIEW test.v1 AS SELECT F59,F61 FROM test.tb2 limit 50 ;
-SELECT * FROM test.v1 order by F59, F61 ;
+CREATE VIEW test.v1 AS SELECT F59,F61 FROM test.tb2;
+SELECT * FROM test.v1 order by F59, F61 limit 50;
 F59	F61
 1	0000000001
 2	0000000002
@@ -9738,8 +9788,8 @@ F59	F61
 76710	NULL
 569300	NULL
 drop view test.v1 ;
-CREATE VIEW test.v1 AS SELECT * FROM test.tb2 order by f59, f60, f61 limit 20 ;
-SELECT * FROM test.v1 order by f59,f60,f61 ;
+CREATE VIEW test.v1 AS SELECT * FROM test.tb2 order by f59, f60, f61;
+SELECT * FROM test.v1 order by f59,f60,f61 limit 20;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
@@ -9762,8 +9812,8 @@ f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	
 100	4	0000000004	0000000000000000000000000000000000000000000000000000000000000004	0000000004	0000000000000000000000000000000000000000000000000000000000000004	-2	3.300000000000000000000000000000	4	3.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494347e-38	1.17549e-38	1.175494355e-38	01.17549e-38	00000001.175494355e-38	01.17549e-38	00000001.175494355e-38	1000-01-04	838:59:55	1970-01-05 00:00:04	1970-01-05 00:00:04	1905	1905	1905	1enum	2set
 100	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
 drop view test.v1 ;
-CREATE VIEW test.v1 AS SELECT F59,f61 FROM test.tb2 limit 20 ;
-SELECT * FROM test.v1 order by f59,f61 desc limit 50;
+CREATE VIEW test.v1 AS SELECT F59,f61 FROM test.tb2;
+SELECT * FROM test.v1 order by f59,f61 desc limit 20;
 F59	f61
 1	0000000001
 2	0000000002
@@ -9774,17 +9824,17 @@ F59	f61
 8	0000000008
 9	0000000009
 10	0000000010
+15	NULL
+17	0000000016
+19	0000000014
+22	NULL
+24	NULL
+27	0000000026
+29	0000000024
+34	NULL
+94	NULL
 100	0000000004
-250	NULL
-340	NULL
-441	NULL
-660	NULL
-2550	NULL
-2760	NULL
-3330	NULL
-3410	NULL
-76710	NULL
-569300	NULL
+100	NULL
 drop view test.v1 ;
 
 Testcase 3.3.1.54 
@@ -10888,7 +10938,7 @@ CREATE ALGORITHM = TEMPTABLE VIEW v1 (f6
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10896,7 +10946,7 @@ CREATE VIEW v1 AS SELECT f59 AS f61 FROM
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10904,7 +10954,7 @@ CREATE VIEW v1 AS SELECT f61 FROM v2;
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10912,7 +10962,7 @@ CREATE VIEW v1 AS SELECT (SELECT f60 FRO
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10920,7 +10970,7 @@ CREATE VIEW v1 AS SELECT f61 FROM t1 HAV
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10928,7 +10978,7 @@ CREATE VIEW v1 AS SELECT f61 FROM t1 GRO
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10936,7 +10986,7 @@ CREATE VIEW v1 AS SELECT SUM(f59) AS f61
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10944,7 +10994,7 @@ CREATE VIEW v1 AS SELECT DISTINCTROW(f61
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10952,7 +11002,7 @@ CREATE VIEW v1 AS SELECT DISTINCT(f61)  
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
diff -Nrup a/mysql-test/suite/funcs_1/r/myisam_views.result b/mysql-test/suite/funcs_1/r/myisam_views.result
--- a/mysql-test/suite/funcs_1/r/myisam_views.result	2007-09-24 15:30:28 +02:00
+++ b/mysql-test/suite/funcs_1/r/myisam_views.result	2007-10-05 15:36:32 +02:00
@@ -191,6 +191,58 @@ insert into tb2 (f59,f60,f61) values (10
 INSERT INTO tb2 (f59,f60) VALUES( 299,899 );
 INSERT INTO tb2 (f59,f60) VALUES( 242,79  );
 INSERT INTO tb2 (f59,f60) VALUES( 424,89  );
+SELECT * FROM tb2 ORDER BY f59, f60, f61;
+f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109	f110	f111	f112	f113	f114	f115	f116	f117
+1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set	+2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000
 000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set	+3	3	0000000003	0000000000000000000000000000000000000000000000000000000000000003	0000000003	0000000000000000000000000000000000000000000000000000000000000003	-3	2
 .200000000000000000000000000000	3	2.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494348e-38	1.17549e-38	1.175494354e-38	01.17549e-38	00000001.175494354e-38	01.17549e-38	00000001.175494354e-38	1000-01-03	838:59:56	1970-01-04 00:00:03	1970-01-04 00:00:03	1904	1904	1904	2enum	1set	+4	4	0000000004	0000000000000000000000000000000000000000000000000000000000000004	0000000004	0000000000000000000000000000000000000000000000000000000000000004	-2	3.300000000000000000000000000000	4	3.300000000000000000000000000000	0000000004	000
 000000000000000000000000000003.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494347e-38	1.17549e-38	1.175494355e-38	01.17549e-38	00000001.175494355e-38	01.17549e-38	00000001.175494355e-38	1000-01-04	838:59:55	1970-01-05 00:00:04	1970-01-05 00:00:04	1905	1905	1905	1enum	2set	+4	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	0000000000000000
 0008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+5	5	0000000005	0000000000000000000000000000000000000000000000000000000000000005	0000000005	0000000000000000000000000000000000000000000000000000000000000005	-1	4.400000000000000000000000000000	5	4.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494346e-38	1.17549e-38	1.175494356e-38	01.17549e-38	00000001.175494356e-38	01.17549e-38	00000001.175494356e-38	1000-01-05	838:59:54	1970-01-06 00:00:05	1970-01-06 00:00:05	1906	1906	1906	2enum	1set,2set	+6	6	0000000006	0000000000000000000000000000000000000000000000000000000000000
 006	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0	5.500000000000000000000000000000	6	5.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494345e-38	1.17549e-38	1.175494357e-38	01.17549e-38	00000001.175494357e-38	01.17549e-38	00000001.175494357e-38	1000-01-06	838:59:53	1970-01-07 00:00:06	1970-01-07 00:00:06	1907	1907	1907	1enum	1set	+7	7	0000000007	0000000000000000000000000000000000000000000000000000000000000007	0000000007	0000000000000000000000000000000000000000000000000000000000000007	1	
 6.600000000000000000000000000000	7	6.600000000000000000000000000000	0000000007	000000000000000000000000000000006.600000000000000000000000000000	0000000007	000000000000000000000000000000006.600000000000000000000000000000	-1.175494344e-38	1.175494358e-38	00000001.175494358e-38	00000001.175494358e-38	-1.175494344e-38	1.175494358e-38	00000001.175494358e-38	00000001.175494358e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494344e-38	1.17549e-38	1.175494358e-38	01.17549e-38	00000001.175494358e-38	01.17549e-38	00000001.175494358e-38	1000-01-07	838:59:52	1970-01-08 00:00:07	1970-01-08 00:00:07	1908	1908	1908	2enum	2set	+8	8	0000000008	0000000000000000000000000000000000000000000000000000000000000008	0000000008	0000000000000000000000000000000000000000000000000000000000000008	2	7.700000000000000000000000000000	8	7.700000000000000000000000000000	0000000008	000
 000000000000000000000000000007.700000000000000000000000000000	0000000008	000000000000000000000000000000007.700000000000000000000000000000	-1.175494343e-38	1.175494359e-38	00000001.175494359e-38	00000001.175494359e-38	-1.175494343e-38	1.175494359e-38	00000001.175494359e-38	00000001.175494359e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494343e-38	1.17549e-38	1.175494359e-38	01.17549e-38	00000001.175494359e-38	01.17549e-38	00000001.175494359e-38	1000-01-08	838:59:51	1970-01-09 00:00:08	1970-01-09 00:00:08	1909	1909	1909	1enum	1set,2set	+9	9	0000000009	0000000000000000000000000000000000000000000000000000000000000009	0000000009	0000000000000000000000000000000000000000000000000000000000000009	3	8.800000000000000000000000000000	9	8.800000000000000000000000000000	0000000009	000000000000000000000000000000008.800000000000000000000000000000	0000000009	0000
 00000000000000000000000000008.800000000000000000000000000000	-1.175494342e-38	1.17549436e-38	000000001.17549436e-38	000000001.17549436e-38	-1.175494342e-38	1.17549436e-38	000000001.17549436e-38	000000001.17549436e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494342e-38	1.17549e-38	1.17549436e-38	01.17549e-38	000000001.17549436e-38	01.17549e-38	000000001.17549436e-38	1000-01-09	838:59:50	1970-01-10 00:00:09	1970-01-10 00:00:09	1910	1910	1910	2enum	1set	+10	10	0000000010	0000000000000000000000000000000000000000000000000000000000000010	0000000010	0000000000000000000000000000000000000000000000000000000000000010	4	9.900000000000000000000000000000	10	9.900000000000000000000000000000	0000000010	000000000000000000000000000000009.900000000000000000000000000000	0000000010	000000000000000000000000000000009.900000000000000000000000000000	-1.175494341e-38	1.17
 5494361e-38	00000001.175494361e-38	00000001.175494361e-38	-1.175494341e-38	1.175494361e-38	00000001.175494361e-38	00000001.175494361e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494341e-38	1.17549e-38	1.175494361e-38	01.17549e-38	00000001.175494361e-38	01.17549e-38	00000001.175494361e-38	1000-01-10	838:59:49	1970-01-11 00:00:10	1970-01-11 00:00:10	1911	1911	1911	1enum	2set	+15	87	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+17	15	0000000016	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+19	18	0000000014	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+22	93	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+24	51654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+27	25	0000000026	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+29	28	0000000024	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+34	41	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+94	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+107	105	0000000106	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+107	105	0000000106	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+109	108	0000000104	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+109	108	0000000104	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+195	87	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+207	205	0000000206	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+209	208	0000000204	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+242	79	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+250	87895654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+292	93	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+299	899	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+321	NULL	0000000765	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+323	14376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+340	9984376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+394	41	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+424	89	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+441	16546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+500	NULL	0000000900	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+500	NULL	0000000900	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+500	NULL	0000000900	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+660	876546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+987	41	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+2550	775654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+2760	985654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+3330	764376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+3410	996546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+7876	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+9112	NULL	0000008771	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+76710	226546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
+569300	9114376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
 Use test;
 
 Testcase 3.3.1.1 
@@ -225,27 +277,27 @@ f59	f60	f61
 8	8	0000000008
 9	9	0000000009
 CREATE or REPLACE VIEW v1 AS select f59,f60,f61
-FROM test.tb2 limit 4,3;
-select * FROM v1 order by f59,f60,f61 limit 0,10;
+FROM test.tb2;
+select * FROM v1 order by f59,f60,f61 limit 4,3;
 f59	f60	f61
+4	74	NULL
 5	5	0000000005
 6	6	0000000006
-7	7	0000000007
 CREATE or REPLACE VIEW v1 AS select distinct f59
-FROM test.tb2 limit 4,3;
-select * FROM v1 order by f59 limit 0,10;
+FROM test.tb2;
+select * FROM v1 order by f59 limit 4,3;
 f59
 5
 6
 7
 ALTER VIEW v1 AS select f59
-FROM test.tb2 limit 6,2;
-select * FROM v1 order by f59 limit 0,10;
+FROM test.tb2;
+select * FROM v1 order by f59 limit 6,2;
 f59
+6
 7
-8
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 order by f59 limit 100;
+from tb2 order by f59;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -259,7 +311,7 @@ f59
 8
 9
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 order by f59 asc limit 100;
+from tb2 order by f59 asc;
 select * FROM v1 limit 0,10;
 f59
 1
@@ -273,7 +325,7 @@ f59
 8
 9
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 order by f59 desc limit 100;
+from tb2 order by f59 desc;
 select * FROM v1 limit 0,10;
 f59
 569300
@@ -287,7 +339,7 @@ f59
 987
 660
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 group by f59 limit 100;
+from tb2 group by f59;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -301,7 +353,7 @@ f59
 9
 10
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 group by f59 asc limit 100;
+from tb2 group by f59 asc;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -315,7 +367,7 @@ f59
 9
 10
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 group by f59 desc limit 100;
+from tb2 group by f59 desc;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -329,7 +381,7 @@ f59
 9
 10
 CREATE or REPLACE VIEW v1 AS (select f59 from tb2)
-union (select f59 from t1) limit 100;
+union (select f59 from t1);
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -517,8 +569,8 @@ DROP VIEW  v1;
 Testcase 3.3.1.3 + 3.1.1.4 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
-CREATE VIEW v1 or REPLACE AS Select * from tb2 my_table limit 50;
-ERROR 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 'or REPLACE AS Select * from tb2 my_table limit 50' at line 1
+CREATE VIEW v1 or REPLACE AS Select * from tb2 my_table;
+ERROR 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 'or REPLACE AS Select * from tb2 my_table' at line 1
 CREATE VIEW v1 WITH CASCADED CHECK OPTION AS Select *
 from tb2 my_table limit 50;
 ERROR 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 'WITH CASCADED CHECK OPTION AS Select *
@@ -527,8 +579,8 @@ CREATE VIEW v1 WITH LOCAL CHECK OPTION A
 from tb2 my_table limit 50;
 ERROR 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 'WITH LOCAL CHECK OPTION AS Select *
 from tb2 my_table limit 50' at line 1
-SELECT * FROM tb2 my_table CREATE VIEW As v1 limit 100 ;
-ERROR 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 'CREATE VIEW As v1 limit 100' at line 1
+SELECT * FROM tb2 my_table CREATE VIEW As v1;
+ERROR 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 'CREATE VIEW As v1' at line 1
 CREATE or REPLACE VIEW v1 Select f59, f60
 from test.tb2 my_table where f59 = 250 ;
 ERROR 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 'Select f59, f60
@@ -603,8 +655,8 @@ Union ALL (Select from f1 t1);
 ERROR 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 'from f59 tb2)
 Union ALL (Select from f1 t1)' at line 1
 CREATE or REPLACE view v1 as Select f59, f60
-from tb2 by order f59 limit 100 ;
-ERROR 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 'by order f59 limit 100' at line 2
+from tb2 by order f59;
+ERROR 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 'by order f59' at line 2
 CREATE or REPLACE view v1 as Select f59, f60
 from tb2 by group f59  ;
 ERROR 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 'by group f59' at line 2
@@ -612,12 +664,12 @@ ERROR 42000: You have an error in your S
 Testcase 3.3.1.5 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
-CREATE VIEW v1 SELECT * FROM tb2 limit 100 ;
-ERROR 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 'SELECT * FROM tb2 limit 100' at line 1
-CREATE v1 AS SELECT * FROM tb2 limit 100 ;
-ERROR 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 'v1 AS SELECT * FROM tb2 limit 100' at line 1
-VIEW v1 AS SELECT * FROM tb2 limit 100 ;
-ERROR 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 'VIEW v1 AS SELECT * FROM tb2 limit 100' at line 1
+CREATE VIEW v1 SELECT * FROM tb2;
+ERROR 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 'SELECT * FROM tb2' at line 1
+CREATE v1 AS SELECT * FROM tb2;
+ERROR 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 'v1 AS SELECT * FROM tb2' at line 1
+VIEW v1 AS SELECT * FROM tb2;
+ERROR 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 'VIEW v1 AS SELECT * FROM tb2' at line 1
 CREATE VIEW v1 AS SELECT 1;
 DROP VIEW v1;
 VIEW v1 AS SELECT 1;
@@ -635,45 +687,43 @@ Testcase 3.3.1.6 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
 CREATE or REPLACE                       VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = UNDEFINED VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = MERGE     VIEW v1
-as SELECT * from tb2 limit 100 ;
-Warnings:
-Warning	1354	View merge algorithm can't be used here for now (assumed undefined algorithm)
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE           = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 '= TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE ALGORITHM   TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE ALGORITHM =           VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE TEMPTABLE = ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'TEMPTABLE = ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE TEMPTABLE - ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'TEMPTABLE - ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE GARBAGE   = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'GARBAGE   = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE ALGORITHM = GARBAGE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'GARBAGE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 Drop view if exists v1 ;
 CREATE or REPLACE VIEW v1
 AS SELECT * from tb2 where f59 < 1;
@@ -699,7 +749,7 @@ ERROR 42000: You have an error in your S
 Testcase 3.3.1.7 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
-Create view test.v1 AS Select * from test.tb2 limit 100 ;
+Create view test.v1 AS Select * from test.tb2;
 Alter view test.v1 AS Select F59 from test. tb2 limit 100 ;
 Drop view test.v1 ;
 Create view v1 AS Select * from test.tb2 limit 100 ;
@@ -906,13 +956,13 @@ SELECT * FROM test.v1 order by f59,f60,f
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109	f110	f111	f112	f113	f114	f115	f116	f117
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set	 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000
 000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set	-CREATE OR REPLACE VIEW test.v1 AS SELECT F59 FROM tb2 limit 10,100;
+CREATE OR REPLACE VIEW test.v1 AS SELECT F59 FROM tb2;
 SHOW CREATE VIEW test.v1;
 View	Create View	character_set_client	collation_connection
-v1	CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select `tb2`.`f59` AS `F59` from `tb2` limit 10,100	latin1	latin1_swedish_ci
-SELECT * FROM test.v1 order by F59;
+v1	CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select `tb2`.`f59` AS `F59` from `tb2`	latin1	latin1_swedish_ci
+SELECT * FROM test.v1 order by F59 limit 10,100;
 F59
-4
+10
 15
 17
 19
@@ -965,8 +1015,8 @@ ERROR HY000: 'test.tb2' is not VIEW
 Testcase 3.3.1.15 
 --------------------------------------------------------------------------------
 Drop table if exists test.v1 ;
-CREATE OR REPLACE view test.v1 as select * from tb2 LIMIT 2;
-SELECT * FROM test.v1;
+CREATE OR REPLACE view test.v1 as select * from tb2;
+SELECT * FROM test.v1 ORDER BY f59,f60,f61 LIMIT 2;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109	f110	f111	f112	f113	f114	f115	f116	f117
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set	 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000
 000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set	@@ -1102,8 +1152,8 @@ ERROR HY000: View's SELECT and view's fi
 Testcase 3.3.1.21 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1;
-CREATE VIEW test.v1( F59, F60 ) AS SELECT F59, F60 From tb2 LIMIT 2;
-SELECT * FROM test.v1 order by F59, F60 desc;
+CREATE VIEW test.v1( F59, F60 ) AS SELECT F59, F60 From tb2;
+SELECT * FROM test.v1 order by F59, F60 desc LIMIT 2;
 F59	F60
 1	1
 2	2
@@ -1112,17 +1162,17 @@ Drop view if exists test.v1 ;
 Testcase 3.3.1.22 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1;
-CREATE VIEW test.v1( product ) AS SELECT f59*f60 From tb2 LIMIT 2;
-SELECT * FROM test.v1;
+CREATE VIEW test.v1( product ) AS SELECT f59*f60 From tb2;
+SELECT * FROM test.v1 WHERE product IS NOT NULL ORDER BY product LIMIT 2;
 product
 1
 4
 CREATE OR REPLACE VIEW test.v1( product ) AS SELECT 1*2;
-SELECT * FROM test.v1;
+SELECT * FROM test.v1 LIMIT 2;
 product
 2
 CREATE OR REPLACE VIEW test.v1( product ) AS SELECT USER();
-SELECT * FROM test.v1;
+SELECT * FROM test.v1 LIMIT 2;
 product
 root@localhost
 Drop view if exists test.v1 ;
@@ -1199,8 +1249,8 @@ DROP TEMPORARY TABLE t2;
 Testcase 3.3.1.26 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1;
-Create view test.v1 AS Select * from test.tb2 limit 2 ;
-Select * from test.v1;
+Create view test.v1 AS Select * from test.tb2;
+Select * from test.v1 order by f59, f60, f61 limit 2;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109	f110	f111	f112	f113	f114	f115	f116	f117
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set	 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000
 000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set	@@ -1210,9 +1260,9 @@ Testcase 3.3.1.27 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS test.v1;
 Drop VIEW  IF EXISTS test.v1_1 ;
-Create view test.v1 AS Select * from test.tb2 limit 2 ;
+Create view test.v1 AS Select * from test.tb2;
 Create view test.v1_1 AS Select F59 from test.v1 ;
-Select * from test.v1_1 order by F59 limit 20 ;
+Select * from test.v1_1 order by F59 limit 2;
 F59
 1
 2
@@ -1759,29 +1809,29 @@ Drop view  if exists test.v1 ;
 Drop view  if exists test.v1_main;
 Drop view  if exists test1.v1_1 ;
 Drop database if exists test3 ;
-Create view test.v1 as Select f59, f60 FROM test.tb2 limit 20 ;
-Select * from test.v1 order by f59,f60;
+Create view test.v1 as Select f59, f60 FROM test.tb2;
+Select * from test.v1 order by f59,f60 limit 20;
 f59	f60
 1	1
 2	2
 3	3
 4	4
+4	74
 5	5
 6	6
 7	7
 8	8
 9	9
 10	10
-250	87895654
-340	9984376
-441	16546
-660	876546
-2550	775654
-2760	985654
-3330	764376
-3410	996546
-76710	226546
-569300	9114376
+15	87
+17	15
+19	18
+22	93
+24	51654
+27	25
+29	28
+34	41
+94	74
 Create table test1.t1 (f59 int,f60 int)  ;
 Insert into test1.t1 values (199,507) ;
 Create view test1.v1_1 as Select f59,f60 from test1.t1 ;
@@ -9692,17 +9742,17 @@ DROP TABLE t1_results;
 Testcase 3.3.1.50 - 3.3.1.53
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS test.v1;
-CREATE VIEW test.v1 AS SELECT * FROM test.tb2 limit 5 ;
-SELECT * FROM test.v1 order by f59 ;
+CREATE VIEW test.v1 AS SELECT * FROM test.tb2;
+SELECT * FROM test.v1 order by f59 limit 5;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109	f110	f111	f112	f113	f114	f115	f116	f117
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set	 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000
 000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set	 3	3	0000000003	0000000000000000000000000000000000000000000000000000000000000003	0000000003	0000000000000000000000000000000000000000000000000000000000000003	-3	2
 .200000000000000000000000000000	3	2.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494348e-38	1.17549e-38	1.175494354e-38	01.17549e-38	00000001.175494354e-38	01.17549e-38	00000001.175494354e-38	1000-01-03	838:59:56	1970-01-04 00:00:03	1970-01-04 00:00:03	1904	1904	1904	2enum	1set	 5	5	0000000005	0000000000000000000000000000000000000000000000000000000000000005	0000000005	0000000000000000000000000000000000000000000000000000000000000005	-1	4.400000000000000000000000000000	5	4.400000000000000000000000000000	0000000005	000
 000000000000000000000000000004.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494346e-38	1.17549e-38	1.175494356e-38	01.17549e-38	00000001.175494356e-38	01.17549e-38	00000001.175494356e-38	1000-01-05	838:59:54	1970-01-06 00:00:05	1970-01-06 00:00:05	1906	1906	1906	2enum	1set,2set	-100	4	0000000004	0000000000000000000000000000000000000000000000000000000000000004	0000000004	0000000000000000000000000000000000000000000000000000000000000004	-2	3.300000000000000000000000000000	4	3.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	0000000004	0
 00000000000000000000000000000003.300000000000000000000000000000	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494347e-38	1.17549e-38	1.175494355e-38	01.17549e-38	00000001.175494355e-38	01.17549e-38	00000001.175494355e-38	1000-01-04	838:59:55	1970-01-05 00:00:04	1970-01-05 00:00:04	1905	1905	1905	1enum	2set	+6	6	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0	5.500000000000000000000000000000	6	5.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	-1.175494345e-38	1
 .175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494345e-38	1.17549e-38	1.175494357e-38	01.17549e-38	00000001.175494357e-38	01.17549e-38	00000001.175494357e-38	1000-01-06	838:59:53	1970-01-07 00:00:06	1970-01-07 00:00:06	1907	1907	1907	1enum	1set	 drop view test.v1 ;
-CREATE VIEW test.v1 AS SELECT F59,F61 FROM test.tb2 limit 50 ;
-SELECT * FROM test.v1 order by F59, F61 ;
+CREATE VIEW test.v1 AS SELECT F59,F61 FROM test.tb2;
+SELECT * FROM test.v1 order by F59, F61 limit 50;
 F59	F61
 1	0000000001
 2	0000000002
@@ -9755,8 +9805,8 @@ F59	F61
 76710	NULL
 569300	NULL
 drop view test.v1 ;
-CREATE VIEW test.v1 AS SELECT * FROM test.tb2 order by f59, f60, f61 limit 20 ;
-SELECT * FROM test.v1 order by f59,f60,f61 ;
+CREATE VIEW test.v1 AS SELECT * FROM test.tb2 order by f59, f60, f61;
+SELECT * FROM test.v1 order by f59,f60,f61 limit 20;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109	f110	f111	f112	f113	f114	f115	f116	f117
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set	 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000
 000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set	@@ -9779,8 +9829,8 @@ f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	
 100	4	0000000004	0000000000000000000000000000000000000000000000000000000000000004	0000000004	0000000000000000000000000000000000000000000000000000000000000004	-2	3.300000000000000000000000000000	4	3.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494347e-38	1.17549e-38	1.175494355e-38	01.17549e-38	00000001.175494355e-38	01.17549e-38	00000001.175494355e-38	1000-01-04	838:59:55	1970-01-05 00:00:04	1970-01-05 00:00:04	1905	1905	1905	1enum	2set	 100	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NU
 LL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL
 drop view test.v1 ;
-CREATE VIEW test.v1 AS SELECT F59,f61 FROM test.tb2 limit 20 ;
-SELECT * FROM test.v1 order by f59,f61 desc limit 50;
+CREATE VIEW test.v1 AS SELECT F59,f61 FROM test.tb2;
+SELECT * FROM test.v1 order by f59,f61 desc limit 20;
 F59	f61
 1	0000000001
 2	0000000002
@@ -9791,17 +9841,17 @@ F59	f61
 8	0000000008
 9	0000000009
 10	0000000010
+15	NULL
+17	0000000016
+19	0000000014
+22	NULL
+24	NULL
+27	0000000026
+29	0000000024
+34	NULL
+94	NULL
 100	0000000004
-250	NULL
-340	NULL
-441	NULL
-660	NULL
-2550	NULL
-2760	NULL
-3330	NULL
-3410	NULL
-76710	NULL
-569300	NULL
+100	NULL
 drop view test.v1 ;
 
 Testcase 3.3.1.54 
@@ -10884,7 +10934,7 @@ CREATE ALGORITHM = TEMPTABLE VIEW v1 (f6
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10892,7 +10942,7 @@ CREATE VIEW v1 AS SELECT f59 AS f61 FROM
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10900,7 +10950,7 @@ CREATE VIEW v1 AS SELECT f61 FROM v2;
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10908,7 +10958,7 @@ CREATE VIEW v1 AS SELECT (SELECT f60 FRO
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10916,7 +10966,7 @@ CREATE VIEW v1 AS SELECT f61 FROM t1 HAV
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10924,7 +10974,7 @@ CREATE VIEW v1 AS SELECT f61 FROM t1 GRO
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10932,7 +10982,7 @@ CREATE VIEW v1 AS SELECT SUM(f59) AS f61
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10940,7 +10990,7 @@ CREATE VIEW v1 AS SELECT DISTINCTROW(f61
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10948,7 +10998,7 @@ CREATE VIEW v1 AS SELECT DISTINCT(f61)  
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
diff -Nrup a/mysql-test/suite/funcs_1/r/ndb_views.result b/mysql-test/suite/funcs_1/r/ndb_views.result
--- a/mysql-test/suite/funcs_1/r/ndb_views.result	2007-09-24 15:30:28 +02:00
+++ b/mysql-test/suite/funcs_1/r/ndb_views.result	2007-10-05 15:36:32 +02:00
@@ -169,6 +169,58 @@ insert into tb2 (f59,f60,f61) values (10
 INSERT INTO tb2 (f59,f60) VALUES( 299,899 );
 INSERT INTO tb2 (f59,f60) VALUES( 242,79  );
 INSERT INTO tb2 (f59,f60) VALUES( 424,89  );
+SELECT * FROM tb2 ORDER BY f59, f60, f61;
+f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
+1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
+2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
+3	3	0000000003	0000000000000000000000000000000000000000000000000000000000000003	0000000003	0000000000000000000000000000000000000000000000000000000000000003	-3	2.200000000000000000000000000000	3	2.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494348e-38	1.17549e-38	1.175494354e-38	01.17549e-38	00000001.175494354e-38	01.17549e-38	00000001.175494354e-38	1000-01-03	838:59:56	1970-01-04 00:00:03	1970-01-04 00:00:03	1904	1904	1904	2enum	1set
+4	4	0000000004	0000000000000000000000000000000000000000000000000000000000000004	0000000004	0000000000000000000000000000000000000000000000000000000000000004	-2	3.300000000000000000000000000000	4	3.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494347e-38	1.17549e-38	1.175494355e-38	01.17549e-38	00000001.175494355e-38	01.17549e-38	00000001.175494355e-38	1000-01-04	838:59:55	1970-01-05 00:00:04	1970-01-05 00:00:04	1905	1905	1905	1enum	2set
+4	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+5	5	0000000005	0000000000000000000000000000000000000000000000000000000000000005	0000000005	0000000000000000000000000000000000000000000000000000000000000005	-1	4.400000000000000000000000000000	5	4.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494346e-38	1.17549e-38	1.175494356e-38	01.17549e-38	00000001.175494356e-38	01.17549e-38	00000001.175494356e-38	1000-01-05	838:59:54	1970-01-06 00:00:05	1970-01-06 00:00:05	1906	1906	1906	2enum	1set,2set
+6	6	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0	5.500000000000000000000000000000	6	5.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494345e-38	1.17549e-38	1.175494357e-38	01.17549e-38	00000001.175494357e-38	01.17549e-38	00000001.175494357e-38	1000-01-06	838:59:53	1970-01-07 00:00:06	1970-01-07 00:00:06	1907	1907	1907	1enum	1set
+7	7	0000000007	0000000000000000000000000000000000000000000000000000000000000007	0000000007	0000000000000000000000000000000000000000000000000000000000000007	1	6.600000000000000000000000000000	7	6.600000000000000000000000000000	0000000007	000000000000000000000000000000006.600000000000000000000000000000	0000000007	000000000000000000000000000000006.600000000000000000000000000000	-1.175494344e-38	1.175494358e-38	00000001.175494358e-38	00000001.175494358e-38	-1.175494344e-38	1.175494358e-38	00000001.175494358e-38	00000001.175494358e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494344e-38	1.17549e-38	1.175494358e-38	01.17549e-38	00000001.175494358e-38	01.17549e-38	00000001.175494358e-38	1000-01-07	838:59:52	1970-01-08 00:00:07	1970-01-08 00:00:07	1908	1908	1908	2enum	2set
+8	8	0000000008	0000000000000000000000000000000000000000000000000000000000000008	0000000008	0000000000000000000000000000000000000000000000000000000000000008	2	7.700000000000000000000000000000	8	7.700000000000000000000000000000	0000000008	000000000000000000000000000000007.700000000000000000000000000000	0000000008	000000000000000000000000000000007.700000000000000000000000000000	-1.175494343e-38	1.175494359e-38	00000001.175494359e-38	00000001.175494359e-38	-1.175494343e-38	1.175494359e-38	00000001.175494359e-38	00000001.175494359e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494343e-38	1.17549e-38	1.175494359e-38	01.17549e-38	00000001.175494359e-38	01.17549e-38	00000001.175494359e-38	1000-01-08	838:59:51	1970-01-09 00:00:08	1970-01-09 00:00:08	1909	1909	1909	1enum	1set,2set
+9	9	0000000009	0000000000000000000000000000000000000000000000000000000000000009	0000000009	0000000000000000000000000000000000000000000000000000000000000009	3	8.800000000000000000000000000000	9	8.800000000000000000000000000000	0000000009	000000000000000000000000000000008.800000000000000000000000000000	0000000009	000000000000000000000000000000008.800000000000000000000000000000	-1.175494342e-38	1.17549436e-38	000000001.17549436e-38	000000001.17549436e-38	-1.175494342e-38	1.17549436e-38	000000001.17549436e-38	000000001.17549436e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494342e-38	1.17549e-38	1.17549436e-38	01.17549e-38	000000001.17549436e-38	01.17549e-38	000000001.17549436e-38	1000-01-09	838:59:50	1970-01-10 00:00:09	1970-01-10 00:00:09	1910	1910	1910	2enum	1set
+10	10	0000000010	0000000000000000000000000000000000000000000000000000000000000010	0000000010	0000000000000000000000000000000000000000000000000000000000000010	4	9.900000000000000000000000000000	10	9.900000000000000000000000000000	0000000010	000000000000000000000000000000009.900000000000000000000000000000	0000000010	000000000000000000000000000000009.900000000000000000000000000000	-1.175494341e-38	1.175494361e-38	00000001.175494361e-38	00000001.175494361e-38	-1.175494341e-38	1.175494361e-38	00000001.175494361e-38	00000001.175494361e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494341e-38	1.17549e-38	1.175494361e-38	01.17549e-38	00000001.175494361e-38	01.17549e-38	00000001.175494361e-38	1000-01-10	838:59:49	1970-01-11 00:00:10	1970-01-11 00:00:10	1911	1911	1911	1enum	2set
+15	87	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+17	15	0000000016	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+19	18	0000000014	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+22	93	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+24	51654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+27	25	0000000026	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+29	28	0000000024	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+34	41	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+94	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+107	105	0000000106	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+107	105	0000000106	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+109	108	0000000104	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+109	108	0000000104	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+195	87	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+207	205	0000000206	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+209	208	0000000204	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+242	79	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+250	87895654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+292	93	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+299	899	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+321	NULL	0000000765	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+323	14376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+340	9984376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+394	41	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+424	89	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+441	16546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+500	NULL	0000000900	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+500	NULL	0000000900	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+500	NULL	0000000900	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+660	876546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+987	41	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+2550	775654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+2760	985654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+3330	764376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+3410	996546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+7876	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+9112	NULL	0000008771	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+76710	226546	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+569300	9114376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
 Use test;
 
 Testcase 3.3.1.1 
@@ -203,27 +255,27 @@ f59	f60	f61
 8	8	0000000008
 9	9	0000000009
 CREATE or REPLACE VIEW v1 AS select f59,f60,f61
-FROM test.tb2 limit 4,3;
-select * FROM v1 order by f59,f60,f61 limit 0,10;
+FROM test.tb2;
+select * FROM v1 order by f59,f60,f61 limit 4,3;
 f59	f60	f61
-10	10	0000000010
-19	18	0000000014
-24	51654	NULL
+4	74	NULL
+5	5	0000000005
+6	6	0000000006
 CREATE or REPLACE VIEW v1 AS select distinct f59
-FROM test.tb2 limit 4,3;
-select * FROM v1 order by f59 limit 0,10;
+FROM test.tb2;
+select * FROM v1 order by f59 limit 4,3;
 f59
-15
-107
-209
+5
+6
+7
 ALTER VIEW v1 AS select f59
-FROM test.tb2 limit 6,2;
-select * FROM v1 order by f59 limit 0,10;
+FROM test.tb2;
+select * FROM v1 order by f59 limit 6,2;
 f59
-10
-34
+6
+7
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 order by f59 limit 100;
+from tb2 order by f59;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -237,7 +289,7 @@ f59
 8
 9
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 order by f59 asc limit 100;
+from tb2 order by f59 asc;
 select * FROM v1 limit 0,10;
 f59
 1
@@ -251,7 +303,7 @@ f59
 8
 9
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 order by f59 desc limit 100;
+from tb2 order by f59 desc;
 select * FROM v1 limit 0,10;
 f59
 569300
@@ -265,7 +317,7 @@ f59
 987
 660
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 group by f59 limit 100;
+from tb2 group by f59;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -279,7 +331,7 @@ f59
 9
 10
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 group by f59 asc limit 100;
+from tb2 group by f59 asc;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -293,7 +345,7 @@ f59
 9
 10
 CREATE or REPLACE VIEW v1 AS select f59
-from tb2 group by f59 desc limit 100;
+from tb2 group by f59 desc;
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -307,7 +359,7 @@ f59
 9
 10
 CREATE or REPLACE VIEW v1 AS (select f59 from tb2)
-union (select f59 from t1) limit 100;
+union (select f59 from t1);
 select * FROM v1 order by f59 limit 0,10;
 f59
 1
@@ -495,8 +547,8 @@ DROP VIEW  v1;
 Testcase 3.3.1.3 + 3.1.1.4 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
-CREATE VIEW v1 or REPLACE AS Select * from tb2 my_table limit 50;
-ERROR 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 'or REPLACE AS Select * from tb2 my_table limit 50' at line 1
+CREATE VIEW v1 or REPLACE AS Select * from tb2 my_table;
+ERROR 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 'or REPLACE AS Select * from tb2 my_table' at line 1
 CREATE VIEW v1 WITH CASCADED CHECK OPTION AS Select *
 from tb2 my_table limit 50;
 ERROR 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 'WITH CASCADED CHECK OPTION AS Select *
@@ -505,8 +557,8 @@ CREATE VIEW v1 WITH LOCAL CHECK OPTION A
 from tb2 my_table limit 50;
 ERROR 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 'WITH LOCAL CHECK OPTION AS Select *
 from tb2 my_table limit 50' at line 1
-SELECT * FROM tb2 my_table CREATE VIEW As v1 limit 100 ;
-ERROR 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 'CREATE VIEW As v1 limit 100' at line 1
+SELECT * FROM tb2 my_table CREATE VIEW As v1;
+ERROR 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 'CREATE VIEW As v1' at line 1
 CREATE or REPLACE VIEW v1 Select f59, f60
 from test.tb2 my_table where f59 = 250 ;
 ERROR 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 'Select f59, f60
@@ -581,8 +633,8 @@ Union ALL (Select from f1 t1);
 ERROR 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 'from f59 tb2)
 Union ALL (Select from f1 t1)' at line 1
 CREATE or REPLACE view v1 as Select f59, f60
-from tb2 by order f59 limit 100 ;
-ERROR 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 'by order f59 limit 100' at line 2
+from tb2 by order f59;
+ERROR 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 'by order f59' at line 2
 CREATE or REPLACE view v1 as Select f59, f60
 from tb2 by group f59  ;
 ERROR 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 'by group f59' at line 2
@@ -590,12 +642,12 @@ ERROR 42000: You have an error in your S
 Testcase 3.3.1.5 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
-CREATE VIEW v1 SELECT * FROM tb2 limit 100 ;
-ERROR 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 'SELECT * FROM tb2 limit 100' at line 1
-CREATE v1 AS SELECT * FROM tb2 limit 100 ;
-ERROR 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 'v1 AS SELECT * FROM tb2 limit 100' at line 1
-VIEW v1 AS SELECT * FROM tb2 limit 100 ;
-ERROR 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 'VIEW v1 AS SELECT * FROM tb2 limit 100' at line 1
+CREATE VIEW v1 SELECT * FROM tb2;
+ERROR 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 'SELECT * FROM tb2' at line 1
+CREATE v1 AS SELECT * FROM tb2;
+ERROR 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 'v1 AS SELECT * FROM tb2' at line 1
+VIEW v1 AS SELECT * FROM tb2;
+ERROR 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 'VIEW v1 AS SELECT * FROM tb2' at line 1
 CREATE VIEW v1 AS SELECT 1;
 DROP VIEW v1;
 VIEW v1 AS SELECT 1;
@@ -613,45 +665,43 @@ Testcase 3.3.1.6 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
 CREATE or REPLACE                       VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = UNDEFINED VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = MERGE     VIEW v1
-as SELECT * from tb2 limit 100 ;
-Warnings:
-Warning	1354	View merge algorithm can't be used here for now (assumed undefined algorithm)
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE           = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 '= TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE ALGORITHM   TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE ALGORITHM =           VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE TEMPTABLE = ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'TEMPTABLE = ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE TEMPTABLE - ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'TEMPTABLE - ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE GARBAGE   = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'GARBAGE   = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 CREATE or REPLACE ALGORITHM = GARBAGE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 ERROR 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 'GARBAGE VIEW v1
-as SELECT * from tb2 limit 100' at line 1
+as SELECT * from tb2' at line 1
 Drop view if exists v1 ;
 CREATE or REPLACE VIEW v1
 AS SELECT * from tb2 where f59 < 1;
@@ -677,7 +727,7 @@ ERROR 42000: You have an error in your S
 Testcase 3.3.1.7 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1 ;
-Create view test.v1 AS Select * from test.tb2 limit 100 ;
+Create view test.v1 AS Select * from test.tb2;
 Alter view test.v1 AS Select F59 from test. tb2 limit 100 ;
 Drop view test.v1 ;
 Create view v1 AS Select * from test.tb2 limit 100 ;
@@ -884,24 +934,21 @@ SELECT * FROM test.v1 order by f59,f60,f
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
-CREATE OR REPLACE VIEW test.v1 AS SELECT F59 FROM tb2 limit 10,100;
+CREATE OR REPLACE VIEW test.v1 AS SELECT F59 FROM tb2;
 SHOW CREATE VIEW test.v1;
 View	Create View	character_set_client	collation_connection
-v1	CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select `tb2`.`f59` AS `F59` from `tb2` limit 10,100	latin1	latin1_swedish_ci
-SELECT * FROM test.v1 order by F59;
+v1	CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select `tb2`.`f59` AS `F59` from `tb2`	latin1	latin1_swedish_ci
+SELECT * FROM test.v1 order by F59 limit 10,100;
 F59
-1
-2
-4
-4
-6
-7
-8
-9
+10
 15
+17
+19
 22
+24
 27
 29
+34
 94
 107
 107
@@ -922,11 +969,14 @@ F59
 441
 500
 500
+500
+660
 987
 2550
 2760
 3330
 3410
+7876
 9112
 76710
 569300
@@ -943,11 +993,11 @@ ERROR HY000: 'test.tb2' is not VIEW
 Testcase 3.3.1.15 
 --------------------------------------------------------------------------------
 Drop table if exists test.v1 ;
-CREATE OR REPLACE view test.v1 as select * from tb2 LIMIT 2;
-SELECT * FROM test.v1;
+CREATE OR REPLACE view test.v1 as select * from tb2;
+SELECT * FROM test.v1 ORDER BY f59,f60,f61 LIMIT 2;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
-340	9984376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
+2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
 Drop view test.v1 ;
 
 Testcase 3.3.1.16 + 3.3.1.17 
@@ -1080,27 +1130,27 @@ ERROR HY000: View's SELECT and view's fi
 Testcase 3.3.1.21 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1;
-CREATE VIEW test.v1( F59, F60 ) AS SELECT F59, F60 From tb2 LIMIT 2;
-SELECT * FROM test.v1 order by F59, F60 desc;
+CREATE VIEW test.v1( F59, F60 ) AS SELECT F59, F60 From tb2;
+SELECT * FROM test.v1 order by F59, F60 desc LIMIT 2;
 F59	F60
 1	1
-340	9984376
+2	2
 Drop view if exists test.v1 ;
 
 Testcase 3.3.1.22 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1;
-CREATE VIEW test.v1( product ) AS SELECT f59*f60 From tb2 LIMIT 2;
-SELECT * FROM test.v1;
+CREATE VIEW test.v1( product ) AS SELECT f59*f60 From tb2;
+SELECT * FROM test.v1 WHERE product IS NOT NULL ORDER BY product LIMIT 2;
 product
-9
-25
+1
+4
 CREATE OR REPLACE VIEW test.v1( product ) AS SELECT 1*2;
-SELECT * FROM test.v1;
+SELECT * FROM test.v1 LIMIT 2;
 product
 2
 CREATE OR REPLACE VIEW test.v1( product ) AS SELECT USER();
-SELECT * FROM test.v1;
+SELECT * FROM test.v1 LIMIT 2;
 product
 root@localhost
 Drop view if exists test.v1 ;
@@ -1177,23 +1227,23 @@ DROP TEMPORARY TABLE t2;
 Testcase 3.3.1.26 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS v1;
-Create view test.v1 AS Select * from test.tb2 limit 2 ;
-Select * from test.v1;
+Create view test.v1 AS Select * from test.tb2;
+Select * from test.v1 order by f59, f60, f61 limit 2;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
-340	9984376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
+2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
 Drop view test.v1 ;
 
 Testcase 3.3.1.27 
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS test.v1;
 Drop VIEW  IF EXISTS test.v1_1 ;
-Create view test.v1 AS Select * from test.tb2 limit 2 ;
+Create view test.v1 AS Select * from test.tb2;
 Create view test.v1_1 AS Select F59 from test.v1 ;
-Select * from test.v1_1 order by F59 limit 20 ;
+Select * from test.v1_1 order by F59 limit 2;
 F59
 1
-340
+2
 Drop view test.v1 ;
 Drop view test.v1_1 ;
 
@@ -1737,29 +1787,29 @@ Drop view  if exists test.v1 ;
 Drop view  if exists test.v1_main;
 Drop view  if exists test1.v1_1 ;
 Drop database if exists test3 ;
-Create view test.v1 as Select f59, f60 FROM test.tb2 limit 20 ;
-Select * from test.v1 order by f59,f60;
+Create view test.v1 as Select f59, f60 FROM test.tb2;
+Select * from test.v1 order by f59,f60 limit 20;
 f59	f60
+1	1
 2	2
 3	3
+4	4
+4	74
 5	5
 6	6
+7	7
+8	8
 9	9
 10	10
+15	87
 17	15
 19	18
+22	93
 24	51654
+27	25
+29	28
 34	41
-107	105
-323	14376
-441	16546
-500	NULL
-500	NULL
-660	876546
-2550	775654
-3330	764376
-3410	996546
-7876	74
+94	74
 Create table test1.t1 (f59 int,f60 int)  ;
 Insert into test1.t1 values (199,507) ;
 Create view test1.v1_1 as Select f59,f60 from test1.t1 ;
@@ -9670,17 +9720,17 @@ DROP TABLE t1_results;
 Testcase 3.3.1.50 - 3.3.1.53
 --------------------------------------------------------------------------------
 DROP VIEW  IF EXISTS test.v1;
-CREATE VIEW test.v1 AS SELECT * FROM test.tb2 limit 5 ;
-SELECT * FROM test.v1 order by f59 ;
+CREATE VIEW test.v1 AS SELECT * FROM test.tb2;
+SELECT * FROM test.v1 order by f59 limit 5;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
-8	8	0000000008	0000000000000000000000000000000000000000000000000000000000000008	0000000008	0000000000000000000000000000000000000000000000000000000000000008	2	7.700000000000000000000000000000	8	7.700000000000000000000000000000	0000000008	000000000000000000000000000000007.700000000000000000000000000000	0000000008	000000000000000000000000000000007.700000000000000000000000000000	-1.175494343e-38	1.175494359e-38	00000001.175494359e-38	00000001.175494359e-38	-1.175494343e-38	1.175494359e-38	00000001.175494359e-38	00000001.175494359e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494343e-38	1.17549e-38	1.175494359e-38	01.17549e-38	00000001.175494359e-38	01.17549e-38	00000001.175494359e-38	1000-01-08	838:59:51	1970-01-09 00:00:08	1970-01-09 00:00:08	1909	1909	1909	1enum	1set,2set
-15	87	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
-340	9984376	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
-2760	985654	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
+2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
+3	3	0000000003	0000000000000000000000000000000000000000000000000000000000000003	0000000003	0000000000000000000000000000000000000000000000000000000000000003	-3	2.200000000000000000000000000000	3	2.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	0000000003	000000000000000000000000000000002.200000000000000000000000000000	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.175494348e-38	1.175494354e-38	00000001.175494354e-38	00000001.175494354e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494348e-38	1.17549e-38	1.175494354e-38	01.17549e-38	00000001.175494354e-38	01.17549e-38	00000001.175494354e-38	1000-01-03	838:59:56	1970-01-04 00:00:03	1970-01-04 00:00:03	1904	1904	1904	2enum	1set
+5	5	0000000005	0000000000000000000000000000000000000000000000000000000000000005	0000000005	0000000000000000000000000000000000000000000000000000000000000005	-1	4.400000000000000000000000000000	5	4.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	0000000005	000000000000000000000000000000004.400000000000000000000000000000	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.175494346e-38	1.175494356e-38	00000001.175494356e-38	00000001.175494356e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494346e-38	1.17549e-38	1.175494356e-38	01.17549e-38	00000001.175494356e-38	01.17549e-38	00000001.175494356e-38	1000-01-05	838:59:54	1970-01-06 00:00:05	1970-01-06 00:00:05	1906	1906	1906	2enum	1set,2set
+6	6	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0000000006	0000000000000000000000000000000000000000000000000000000000000006	0	5.500000000000000000000000000000	6	5.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	0000000006	000000000000000000000000000000005.500000000000000000000000000000	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.175494345e-38	1.175494357e-38	00000001.175494357e-38	00000001.175494357e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494345e-38	1.17549e-38	1.175494357e-38	01.17549e-38	00000001.175494357e-38	01.17549e-38	00000001.175494357e-38	1000-01-06	838:59:53	1970-01-07 00:00:06	1970-01-07 00:00:06	1907	1907	1907	1enum	1set
 drop view test.v1 ;
-CREATE VIEW test.v1 AS SELECT F59,F61 FROM test.tb2 limit 50 ;
-SELECT * FROM test.v1 order by F59, F61 ;
+CREATE VIEW test.v1 AS SELECT F59,F61 FROM test.tb2;
+SELECT * FROM test.v1 order by F59, F61 limit 50;
 F59	F61
 1	0000000001
 2	0000000002
@@ -9733,8 +9783,8 @@ F59	F61
 76710	NULL
 569300	NULL
 drop view test.v1 ;
-CREATE VIEW test.v1 AS SELECT * FROM test.tb2 order by f59, f60, f61 limit 20 ;
-SELECT * FROM test.v1 order by f59,f60,f61 ;
+CREATE VIEW test.v1 AS SELECT * FROM test.tb2 order by f59, f60, f61;
+SELECT * FROM test.v1 order by f59,f60,f61 limit 20;
 f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	f69	f70	f71	f72	f73	f74	f75	f76	f77	f78	f79	f80	f81	f82	f83	f84	f85	f86	f87	f88	f89	f90	f91	f92	f93	f94	f95	f96	f97	f98	f99	f100	f101	f102	f103	f104	f105	f106	f107	f108	f109
 1	1	0000000001	0000000000000000000000000000000000000000000000000000000000000001	0000000001	0000000000000000000000000000000000000000000000000000000000000001	-5	0.000000000000000000000000000000	1	0.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	0000000001	000000000000000000000000000000000.000000000000000000000000000000	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549435e-38	1.175494352e-38	00000001.175494352e-38	00000001.175494352e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549435e-38	1.17549e-38	1.175494352e-38	01.17549e-38	00000001.175494352e-38	01.17549e-38	00000001.175494352e-38	1000-01-01	838:59:58	1970-01-02 00:00:01	1970-01-02 00:00:01	1902	1902	1902	2enum	2set
 2	2	0000000002	0000000000000000000000000000000000000000000000000000000000000002	0000000002	0000000000000000000000000000000000000000000000000000000000000002	-4	1.100000000000000000000000000000	2	1.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	0000000002	000000000000000000000000000000001.100000000000000000000000000000	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.175494349e-38	1.175494353e-38	00000001.175494353e-38	00000001.175494353e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494349e-38	1.17549e-38	1.175494353e-38	01.17549e-38	00000001.175494353e-38	01.17549e-38	00000001.175494353e-38	1000-01-02	838:59:57	1970-01-03 00:00:02	1970-01-03 00:00:02	1903	1903	1903	1enum	1set,2set
@@ -9757,29 +9807,29 @@ f59	f60	f61	f62	f63	f64	f65	f66	f67	f68	
 100	4	0000000004	0000000000000000000000000000000000000000000000000000000000000004	0000000004	0000000000000000000000000000000000000000000000000000000000000004	-2	3.300000000000000000000000000000	4	3.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	0000000004	000000000000000000000000000000003.300000000000000000000000000000	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.175494347e-38	1.175494355e-38	00000001.175494355e-38	00000001.175494355e-38	-1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.17549e-38	1.17549e-38	1.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	01.17549e-38	-1.17549e-38	-1.175494347e-38	1.17549e-38	1.175494355e-38	01.17549e-38	00000001.175494355e-38	01.17549e-38	00000001.175494355e-38	1000-01-04	838:59:55	1970-01-05 00:00:04	1970-01-05 00:00:04	1905	1905	1905	1enum	2set
 100	74	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	7.7	7.7	00000000000000000007.7	00000000000000000008.8	8.8	8.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	0000000008.8	0000000008.8	0000000008.8	8.8	8.8	8.8	8.8	0000000008.8	00000000000000000008.8	0000000008.8	00000000000000000008.8	2000-01-01	00:00:20	0002-02-02 00:00:00	2000-12-31 23:59:59	2000	2000	2000	1enum	1set
 drop view test.v1 ;
-CREATE VIEW test.v1 AS SELECT F59,f61 FROM test.tb2 limit 20 ;
-SELECT * FROM test.v1 order by f59,f61 desc limit 50;
+CREATE VIEW test.v1 AS SELECT F59,f61 FROM test.tb2;
+SELECT * FROM test.v1 order by f59,f61 desc limit 20;
 F59	f61
+1	0000000001
 2	0000000002
 3	0000000003
 5	0000000005
 6	0000000006
+7	0000000007
+8	0000000008
 9	0000000009
 10	0000000010
+15	NULL
 17	0000000016
 19	0000000014
+22	NULL
 24	NULL
+27	0000000026
+29	0000000024
 34	NULL
-107	0000000106
-323	NULL
-441	NULL
-500	0000000900
-500	0000000900
-660	NULL
-2550	NULL
-3330	NULL
-3410	NULL
-7876	NULL
+94	NULL
+100	0000000004
+100	NULL
 drop view test.v1 ;
 
 Testcase 3.3.1.54 
@@ -10882,7 +10932,7 @@ CREATE ALGORITHM = TEMPTABLE VIEW v1 (f6
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10890,7 +10940,7 @@ CREATE VIEW v1 AS SELECT f59 AS f61 FROM
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10898,7 +10948,7 @@ CREATE VIEW v1 AS SELECT f61 FROM v2;
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10906,7 +10956,7 @@ CREATE VIEW v1 AS SELECT (SELECT f60 FRO
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10914,7 +10964,7 @@ CREATE VIEW v1 AS SELECT f61 FROM t1 HAV
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10922,7 +10972,7 @@ CREATE VIEW v1 AS SELECT f61 FROM t1 GRO
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10930,7 +10980,7 @@ CREATE VIEW v1 AS SELECT SUM(f59) AS f61
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10938,7 +10988,7 @@ CREATE VIEW v1 AS SELECT DISTINCTROW(f61
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
@@ -10946,7 +10996,7 @@ CREATE VIEW v1 AS SELECT DISTINCT(f61)  
 INSERT INTO v1 VALUES (1002);
 ERROR HY000: The target table v1 of the INSERT is not insertable-into
 UPDATE v1 SET f61=1007;
-Got one of the listed errors
+ERROR HY000: The target table v1 of the UPDATE is not updatable
 DELETE FROM v1;
 ERROR HY000: The target table v1 of the DELETE is not updatable
 DROP VIEW v1;
diff -Nrup a/mysql-test/suite/funcs_1/views/views_master.inc b/mysql-test/suite/funcs_1/views/views_master.inc
--- a/mysql-test/suite/funcs_1/views/views_master.inc	2007-09-24 15:30:28 +02:00
+++ b/mysql-test/suite/funcs_1/views/views_master.inc	2007-10-05 15:36:32 +02:00
@@ -42,7 +42,7 @@ Bug#10713: mysqldump includes database i
 #     MySQL has also added some vendor-specific enhancements to the standard
 #     SQL requirements.
 
-# FIXME (ML)
+# FIXME (mleich)
 #   - Alter all object names so that they follow the v/t/..<number> scheme or
 #     apply another method which prevents that customer data might be
 #     accidently modified
@@ -107,6 +107,12 @@ insert into tb2 (f59,f60,f61) values (10
 INSERT INTO tb2 (f59,f60) VALUES( 299,899 );
 INSERT INTO tb2 (f59,f60) VALUES( 242,79  );
 INSERT INTO tb2 (f59,f60) VALUES( 424,89  );
+if ($have_bug_11589)
+{
+--disable_ps_protocol
+}
+SELECT * FROM tb2 ORDER BY f59, f60, f61;
+--enable_ps_protocol
 #
 #
 Use test;
@@ -147,7 +153,7 @@ Insert into t1  values (500,9866);
     FROM test.tb2 where f59=250;
     select * FROM v1 order by f60,f61 limit 0,10;
 
-#(02)
+#(02) 
     Drop view if exists v1 ;
     CREATE VIEW v1 AS select f59,f60,f61
     FROM test.tb2 limit 100;
@@ -155,52 +161,52 @@ Insert into t1  values (500,9866);
 
 #(03)
     CREATE or REPLACE VIEW v1 AS select f59,f60,f61
-    FROM test.tb2 limit 4,3;
-    select * FROM v1 order by f59,f60,f61 limit 0,10;
+    FROM test.tb2;
+    select * FROM v1 order by f59,f60,f61 limit 4,3;
 
 #(04)
     CREATE or REPLACE VIEW v1 AS select distinct f59
-    FROM test.tb2 limit 4,3;
-    select * FROM v1 order by f59 limit 0,10;
+    FROM test.tb2;
+    select * FROM v1 order by f59 limit 4,3;
 
 #(05)
     ALTER VIEW v1 AS select f59
-    FROM test.tb2 limit 6,2;
-    select * FROM v1 order by f59 limit 0,10;
+    FROM test.tb2;
+    select * FROM v1 order by f59 limit 6,2;
 
 #(06)
     CREATE or REPLACE VIEW v1 AS select f59
-    from tb2 order by f59 limit 100;
+    from tb2 order by f59;
     select * FROM v1 order by f59 limit 0,10;
 
 #(07)
     CREATE or REPLACE VIEW v1 AS select f59
-    from tb2 order by f59 asc limit 100;
+    from tb2 order by f59 asc;
     select * FROM v1 limit 0,10;
 
 #(08)
     CREATE or REPLACE VIEW v1 AS select f59
-    from tb2 order by f59 desc limit 100;
+    from tb2 order by f59 desc;
     select * FROM v1 limit 0,10;
 
 #(09)
     CREATE or REPLACE VIEW v1 AS select f59
-    from tb2 group by f59 limit 100;
+    from tb2 group by f59;
     select * FROM v1 order by f59 limit 0,10;
 
 #(10)
     CREATE or REPLACE VIEW v1 AS select f59
-    from tb2 group by f59 asc limit 100;
+    from tb2 group by f59 asc;
     select * FROM v1 order by f59 limit 0,10;
 
 #(11)
     CREATE or REPLACE VIEW v1 AS select f59
-    from tb2 group by f59 desc limit 100;
+    from tb2 group by f59 desc;
     select * FROM v1 order by f59 limit 0,10;
 
 #(12)
     CREATE or REPLACE VIEW v1 AS (select f59 from tb2)
-    union (select f59 from t1) limit 100;
+    union (select f59 from t1);
     select * FROM v1 order by f59 limit 0,10;
 
 #(13)
@@ -260,12 +266,12 @@ CREATE TABLE t1 (f1 BIGINT) ;
 
 # SELECT INTO is illegal
 SET @x=0;
---error 1350
+--error ER_VIEW_SELECT_CLAUSE
 CREATE or REPLACE VIEW v1 AS Select 1 INTO @x;
 Select @x;
 
 # Subquery in the FROM clause is illegal
---error 1349
+--error ER_VIEW_SELECT_DERIVED
 CREATE or REPLACE VIEW v1 AS Select 1
 FROM (SELECT 1 FROM t1) my_table;
 
@@ -282,23 +288,16 @@ SELECT @a ;
 SELECT * FROM t1;
 DROP TRIGGER tr1 ;
 SET @a:=0 ;
---error 1347
+--error ER_WRONG_OBJECT
 CREATE TRIGGER tr1 BEFORE INSERT ON v1 FOR EACH ROW SET @a:=1 ;
 
-# RENAME VIEW is not available even when we try it via rename table.
-# FIXME: Write a bug report for the ugly error message
-#        1017: Can't find file: './test/v1.frm' (errno: 2),
-#        because the much more beautiful
-#        1347: 'test.v1' is not BASE TABLE
-#        exists.
---replace_result '\\' '/'
-# MLML --error 1017
 RENAME TABLE v1 TO v2;
---error 1064
+# RENAME VIEW is not available even when we try it via rename table.
+--error ER_PARSE_ERROR
 RENAME VIEW  v2 TO v1;
-#--error 1347
+#--error ER_WRONG_OBJECT
 ALTER TABLE v2 RENAME AS v1;
---error 1064
+--error ER_PARSE_ERROR
 ALTER VIEW  v1 RENAME AS v2;
 
 # VIEWs cannot contain a PRIMARY KEY or have an Index.
@@ -310,12 +309,12 @@ DROP VIEW  IF EXISTS v2 ;
 CREATE TABLE t1 ( f1 DATE, f2 BLOB, f3 DOUBLE );
 CREATE VIEW  v1 AS SELECT f1, f2, f3 FROM t1;
 ALTER  TABLE t1 ADD PRIMARY KEY(f1);
---error 1347
+--error ER_WRONG_OBJECT
 ALTER  TABLE v1 ADD PRIMARY KEY(f1);
---error 1064
+--error ER_PARSE_ERROR
 ALTER  VIEW  v1 ADD PRIMARY KEY(f1);
 CREATE INDEX t1_idx ON t1(f3);
---error 1347
+--error ER_WRONG_OBJECT
 CREATE INDEX v1_idx ON v1(f3);
 DROP TABLE t1;
 DROP VIEW  v1;
@@ -333,21 +332,21 @@ let $message= Testcase 3.3.1.3 + 3.1.1.4
 DROP VIEW  IF EXISTS v1 ;
 --enable_warnings
 # REPLACE after VIEW name
---error 1064
-CREATE VIEW v1 or REPLACE AS Select * from tb2 my_table limit 50;
+--error ER_PARSE_ERROR
+CREATE VIEW v1 or REPLACE AS Select * from tb2 my_table;
 # CHECK OPTION before AS SELECT
---error 1064
+--error ER_PARSE_ERROR
 CREATE VIEW v1 WITH CASCADED CHECK OPTION AS Select *
 from tb2 my_table limit 50;
 # CHECK OPTION before AS SELECT
---error 1064
+--error ER_PARSE_ERROR
 CREATE VIEW v1 WITH LOCAL CHECK OPTION AS Select *
 from tb2 my_table limit 50;
 # CREATE after SELECT
---error 1064
-SELECT * FROM tb2 my_table CREATE VIEW As v1 limit 100 ;
+--error ER_PARSE_ERROR
+SELECT * FROM tb2 my_table CREATE VIEW As v1;
 # AS forgotten
---error 1064
+--error ER_PARSE_ERROR
 CREATE or REPLACE VIEW v1 Select f59, f60
 from test.tb2 my_table where f59 = 250 ;
 # positive case
@@ -355,60 +354,60 @@ CREATE OR REPLACE VIEW v1 AS SELECT F59,
 FROM test.tb2 my_table WITH CASCADED CHECK OPTION;
 DROP VIEW v1;
 # REPLACE OR CREATE instead of CREATE OR REPLACE
---error 1064
+--error ER_PARSE_ERROR
 REPLACE OR CREATE VIEW v1 AS SELECT F59, F60
 FROM test.tb2 my_table WITH CASCADED CHECK OPTION;
 # AS after SELECT
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE VIEW v1 SELECT AS F59, F60
 FROM test.tb2 my_table WITH CASCADED CHECK OPTION;
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE VIEW v1 AS SELECT F59, F60
 FROM test.tb2 my_table CASCADED WITH CHECK OPTION;
 # OPTION CHECK instead of CHECK OPTION
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE VIEW v1 AS SELECT F59, F60
 FROM test.tb2 my_table WITH CASCADED OPTION CHECK;
 # CHECK OPTION before WITH
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE VIEW v1 AS SELECT F59, F60
 FROM test.tb2 my_table CHECK OPTION WITH CASCADED;
 # CHECK OPTION before AS SELECT
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE VIEW v1 WITH CASCADED CHECK OPTION
 AS SELECT F59, F60 FROM test.tb2 my_table;
 # VIEW <viewname> after AS SELECT
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE AS SELECT F59, F60
 FROM test.tb2 my_table VIEW v1 WITH CASCADED CHECK OPTION;
 # VIEW <viewname> after CHECK OPTION
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE AS SELECT F59, F60
 FROM test.tb2 my_table WITH CASCADED CHECK OPTION VIEW v1;
 
 # Variants with LOCAL CHECK OPTION
---error 1064
+--error ER_PARSE_ERROR
 REPLACE OR CREATE VIEW v1 AS SELECT F59, F60
 FROM test.tb2 my_table WITH LOCAL CHECK OPTION;
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE VIEW v1 SELECT AS F59, F60
 FROM test.tb2 my_table WITH LOCAL CHECK OPTION;
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE VIEW v1 AS SELECT F59, F60
 FROM test.tb2 my_table LOCAL WITH CHECK OPTION;
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE VIEW v1 AS SELECT F59, F60
 FROM test.tb2 my_table WITH LOCAL OPTION CHECK;
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE VIEW v1 AS SELECT F59, F60
 FROM test.tb2 my_table CHECK OPTION WITH LOCAL;
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE VIEW v1 WITH CASCADED CHECK OPTION
 AS SELECT F59, F60 FROM test.tb2 my_table;
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE AS SELECT F59, F60
 FROM test.tb2 my_table VIEW v1 WITH LOCAL CHECK OPTION;
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE AS SELECT F59, F60
 FROM test.tb2 my_table WITH LOCAL CHECK OPTION VIEW v1;
 
@@ -419,15 +418,15 @@ CREATE table t1 (f1 int ,f2 int)  ;
 INSERT INTO t1 values (235, 22);
 INSERT INTO t1 values (554, 11);
 # SELECTs of UNION in braces
---error 1064
+--error ER_PARSE_ERROR
 CREATE or REPLACE view v1 as (Select from f59 tb2)
 Union ALL (Select from f1 t1);
 # by before order
---error 1064
+--error ER_PARSE_ERROR
 CREATE or REPLACE view v1 as Select f59, f60
-from tb2 by order f59 limit 100 ;
+from tb2 by order f59;
 # by before group
---error 1064
+--error ER_PARSE_ERROR
 CREATE or REPLACE view v1 as Select f59, f60
 from tb2 by group f59  ;
 
@@ -442,24 +441,24 @@ let $message= Testcase 3.3.1.5 ;
 --disable_warnings
 DROP VIEW  IF EXISTS v1 ;
 --enable_warnings
---error 1064
-CREATE VIEW v1 SELECT * FROM tb2 limit 100 ;
---error 1064
-CREATE v1 AS SELECT * FROM tb2 limit 100 ;
---error 1064
-VIEW v1 AS SELECT * FROM tb2 limit 100 ;
+--error ER_PARSE_ERROR
+CREATE VIEW v1 SELECT * FROM tb2;
+--error ER_PARSE_ERROR
+CREATE v1 AS SELECT * FROM tb2;
+--error ER_PARSE_ERROR
+VIEW v1 AS SELECT * FROM tb2;
 # positive case
 CREATE VIEW v1 AS SELECT 1;
 DROP VIEW v1;
---error 1064
+--error ER_PARSE_ERROR
        VIEW v1 AS SELECT 1;
---error 1064
+--error ER_PARSE_ERROR
 CREATE      v1 AS SELECT 1;
---error 1064
+--error ER_PARSE_ERROR
 CREATE VIEW    AS SELECT 1;
---error 1064
+--error ER_PARSE_ERROR
 CREATE VIEW v1    SELECT 1;
---error 1064
+--error ER_PARSE_ERROR
 CREATE VIEW v1 AS         ;
 
 
@@ -480,37 +479,37 @@ let $message= Testcase 3.3.1.6 ;
 DROP VIEW  IF EXISTS v1 ;
 --enable_warnings
 CREATE or REPLACE                       VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = UNDEFINED VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = MERGE     VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 CREATE or REPLACE ALGORITHM = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 # negative test cases
---error 1064
+--error ER_PARSE_ERROR
 CREATE or REPLACE           = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
---error 1064
+as SELECT * from tb2;
+--error ER_PARSE_ERROR
 CREATE or REPLACE ALGORITHM   TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
---error 1064
+as SELECT * from tb2;
+--error ER_PARSE_ERROR
 CREATE or REPLACE ALGORITHM =           VIEW v1
-as SELECT * from tb2 limit 100 ;
---error 1064
+as SELECT * from tb2;
+--error ER_PARSE_ERROR
 CREATE or REPLACE TEMPTABLE = ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100 ;
---error 1064
+as SELECT * from tb2;
+--error ER_PARSE_ERROR
 CREATE or REPLACE TEMPTABLE - ALGORITHM VIEW v1
-as SELECT * from tb2 limit 100 ;
---error 1064
+as SELECT * from tb2;
+--error ER_PARSE_ERROR
 CREATE or REPLACE GARBAGE   = TEMPTABLE VIEW v1
-as SELECT * from tb2 limit 100 ;
---error 1064
+as SELECT * from tb2;
+--error ER_PARSE_ERROR
 CREATE or REPLACE ALGORITHM = GARBAGE VIEW v1
-as SELECT * from tb2 limit 100 ;
+as SELECT * from tb2;
 Drop view if exists v1 ;
 
 CREATE or REPLACE VIEW v1
@@ -522,16 +521,16 @@ AS SELECT * from tb2 where f59 < 1 WITH 
 CREATE or REPLACE VIEW v1
 AS SELECT * from tb2 where f59 < 1 WITH LOCAL    CHECK OPTION;
 # negative test cases
---error 1064
+--error ER_PARSE_ERROR
 CREATE or REPLACE VIEW v1
 AS SELECT * from tb2 where f59 < 1 WITH NO       CHECK OPTION;
---error 1064
+--error ER_PARSE_ERROR
 CREATE or REPLACE VIEW v1
 AS SELECT * from tb2 where f59 < 1      CASCADED CHECK OPTION;
---error 1064
+--error ER_PARSE_ERROR
 CREATE or REPLACE VIEW v1
 AS SELECT * from tb2 where f59 < 1 WITH CASCADED       OPTION;
---error 1064
+--error ER_PARSE_ERROR
 CREATE or REPLACE VIEW v1
 AS SELECT * from tb2 where f59 < 1 WITH CASCADED CHECK       ;
 
@@ -543,12 +542,12 @@ let $message= Testcase 3.3.1.7 ;
 #                   view names are accepted, at creation time, alteration time,
 #                   and drop time.
 ###############################################################################
-# Note(ML): non-qualified view name means a view name without preceeding
-#           database name
+# Note(mleich): non-qualified view name means a view name without preceeding
+#               database name
 --disable_warnings
 DROP VIEW  IF EXISTS v1 ;
 --enable_warnings
-Create view test.v1 AS Select * from test.tb2 limit 100 ;
+Create view test.v1 AS Select * from test.tb2;
 Alter view test.v1 AS Select F59 from test. tb2 limit 100 ;
 Drop view test.v1 ;
 Create view v1 AS Select * from test.tb2 limit 100 ;
@@ -561,11 +560,11 @@ let $message= Testcase 3.3.1.A0 ;
 ###############################################################################
 # Testcase 3.3.1.A0: Ensure that view names are treated case sensitive.
 ###############################################################################
-# Note(ML): Maybe this test produces portability problems on Windows.
-#           FIXME There should be a test outside this one checking the
-#                 creation of objects with cases sensitive names.
-#                 If we have this test the following sub testcase should
-#                 be deleted.
+# Note(mleich): Maybe this test produces portability problems on Windows.
+#               FIXME There should be a test outside this one checking the
+#                     creation of objects with cases sensitive names.
+#                     If we have this test the following sub testcase should
+#                     be deleted.
 --disable_warnings
 DROP TABLE IF EXISTS t1 ;
 DROP VIEW  IF EXISTS v1 ;
@@ -576,8 +575,8 @@ INSERT INTO t1 VALUES(1111), (2222);
 CREATE VIEW v1 AS SELECT * FROM t1 WHERE f1 = 1111;
 # We get here the sql code
 # - 0    on OS with    cases sensitive view names (Example: UNIX)
-# - 1050 on OS without cases sensitive view names (Example: WINDOWS)
---error 0,1050
+# - ER_TABLE_EXISTS_ERROR on OS without cases sensitive view names (Example: WINDOWS)
+--error 0,ER_TABLE_EXISTS_ERROR
 CREATE VIEW V1 AS SELECT * FROM t1 WHERE f1 = 2222;
 SELECT * FROM v1;
 # SELECT * FROM V1;
@@ -595,20 +594,20 @@ let $message= Testcase 3.3.1.8 ;
 #                   that an appropriate error message is returned when the name
 #                   is rejected.
 ###############################################################################
-# Note(ML): There could be more negative tests here, but I assume that the
-#           server routines checking if a table or view name is acceptable are
-#           heavily tested in tests checking the creation of tables.
---error 1064
+# Note(mleich): There could be more negative tests here, but I assume that the
+#               server routines checking if a table or view name is acceptable
+#               are heavily tested in tests checking the creation of tables.
+--error ER_PARSE_ERROR
 Create view select AS Select * from test.tb2 limit 100;
---error 1064
+--error ER_PARSE_ERROR
 Create view as AS Select * from test.tb2 limit 100;
---error 1064
+--error ER_PARSE_ERROR
 Create view where AS Select * from test.tb2 limit 100;
---error 1064
+--error ER_PARSE_ERROR
 Create view from AS Select * from test.tb2 limit 100;
---error 1064
+--error ER_PARSE_ERROR
 Create view while AS Select * from test.tb2 limit 100;
---error 1064
+--error ER_PARSE_ERROR
 Create view asdkj*(&*&&^ as Select * from test.tb2 limit 100 ;
 --disable_warnings
 Drop view if exists test.procedure ;
@@ -623,10 +622,11 @@ let $message= Testcase 3.3.1.9 ;
 # Testcase 3.3.1.9: Ensure that a reference to a non-existent view is rejected
 #                   with an appropriate error message
 ###############################################################################
-# Note(ML): The SELECT statement syntax does not contain any functionality to
-#           claim, that the object after FROM must be a VIEW. SHOW's will be
-#           checked in 3.3.11 Checks on SHOW, EXPLAIN, and DESCRIBE statements.
-#           Let's check here a view based on a dropped view or table.
+# Note(mleich): The SELECT statement syntax does not contain any functionality
+#               to claim, that the object after FROM must be a VIEW. SHOW's will
+#               be checked in
+#                  3.3.11 Checks on SHOW, EXPLAIN, and DESCRIBE statements.
+#               Let's check here a view based on a dropped view or table.
 --disable_warnings
 Drop TABLE IF EXISTS t1 ;
 Drop VIEW  IF EXISTS v1;
@@ -640,32 +640,32 @@ CREATE VIEW v2 AS SELECT *  FROM v1;
 
 # Only negative cases, positive cases will be checked later:
 DROP TABLE t1;
---error 1356
+--error ER_VIEW_INVALID
 SELECT * FROM v1;
---error 1356
+--error ER_VIEW_INVALID
 DELETE FROM v1;
---error 1356
+--error ER_VIEW_INVALID
 UPDATE v1 SET f1 = 'aaaaa';
---error 1356
+--error ER_VIEW_INVALID
 INSERT INTO v1 SET f1 = "fffff";
 # v2 is based on v1, which is now invalid
---error 1356
+--error ER_VIEW_INVALID
 SELECT * FROM v2;
---error 1356
+--error ER_VIEW_INVALID
 DELETE FROM v2;
---error 1356
+--error ER_VIEW_INVALID
 UPDATE v2 SET f1 = 'aaaaa';
---error 1356
+--error ER_VIEW_INVALID
 INSERT INTO v2 SET f1 = "fffff";
 DROP VIEW v1;
 # v2 is based on v1, which is now dropped
---error 1356
+--error ER_VIEW_INVALID
 SELECT * FROM v2;
---error 1356
+--error ER_VIEW_INVALID
 DELETE FROM v2;
---error 1356
+--error ER_VIEW_INVALID
 UPDATE v2 SET f1 = 'aaaaa';
---error 1356
+--error ER_VIEW_INVALID
 INSERT INTO v2 SET f1 = "fffff";
 
 DROP VIEW v2;
@@ -677,11 +677,11 @@ DROP VIEW  IF EXISTS v1 ;
 --enable_warnings
 CREATE TABLE t1 (f1 FLOAT);
 # Create a new VIEW based on itself
---error 1146
+--error ER_NO_SUCH_TABLE
 CREATE VIEW v1 AS SELECT * FROM v1;
 # Replace a valid VIEW with one new based on itself
 CREATE VIEW  v1 AS SELECT * FROM t1;
---error 1146
+--error ER_NO_SUCH_TABLE
 CREATE or REPLACE VIEW  v1 AS SELECT * FROM v1;
 
 DROP VIEW  v1;
@@ -697,9 +697,9 @@ let $message= Testcase 3.3.1.10 ;
 Drop view if exists test.v1 ;
 --enable_warnings
 Create view test.v1 AS Select * from test.tb2 ;
---error 1050
+--error ER_TABLE_EXISTS_ERROR
 Create view test.v1 AS Select F59 from test.tb2 ;
---error 1050
+--error ER_TABLE_EXISTS_ERROR
 Create view      v1 AS Select F59 from test.tb2 ;
 
 
@@ -710,18 +710,18 @@ let $message= Testcase 3.3.1.11 ;
 #                    table with the same name in the same database.
 ###############################################################################
 # The VIEW should get the same name like an already existing TABLE.
---error 1050
+--error ER_TABLE_EXISTS_ERROR
 Create view test.tb2 AS Select f59,f60 from test.tb2 limit 100 ;
---error 1050
+--error ER_TABLE_EXISTS_ERROR
 Create view      tb2 AS Select f59,f60 from test.tb2 limit 100 ;
 # The TABLE should get the same name like an already existing VIEW.
 --disable_warnings
 Drop view if exists test.v111 ;
 --enable_warnings
 Create view test.v111 as select * from tb2 limit 50;
---error 1050
+--error ER_TABLE_EXISTS_ERROR
 Create table test.v111(f1 int );
---error 1050
+--error ER_TABLE_EXISTS_ERROR
 Create table      v111(f1 int );
 DROP VIEW test.v111;
 
@@ -825,9 +825,9 @@ if ($have_bug_11589)
 SELECT * FROM test.v1 order by f59,f60,f61,f62,f63,f64,f65;
 --enable_ps_protocol
 # Switch the SELECT but not the base table
-CREATE OR REPLACE VIEW test.v1 AS SELECT F59 FROM tb2 limit 10,100;
+CREATE OR REPLACE VIEW test.v1 AS SELECT F59 FROM tb2;
 SHOW CREATE VIEW test.v1;
-SELECT * FROM test.v1 order by F59;
+SELECT * FROM test.v1 order by F59 limit 10,100;
 Drop table test.t1 ;
 Drop view  test.v1 ;
 
@@ -839,9 +839,9 @@ let $message= Testcase 3.3.1.14 ;
 #                    used to create a view using the name of an existing base
 #                    table, it fails with an appropriate error message.
 ###############################################################################
---error 1347
+--error ER_WRONG_OBJECT
 CREATE OR REPLACE VIEW test.tb2 AS SELECT * From tb2 LIMIT 2;
---error 1347
+--error ER_WRONG_OBJECT
 CREATE OR REPLACE VIEW tb2 AS SELECT * From tb2 LIMIT 2;
 
 
@@ -856,12 +856,12 @@ let $message= Testcase 3.3.1.15 ;
 --disable_warnings
 Drop table if exists test.v1 ;
 --enable_warnings
-CREATE OR REPLACE view test.v1 as select * from tb2 LIMIT 2;
+CREATE OR REPLACE view test.v1 as select * from tb2;
 if ($have_bug_11589)
 {
 --disable_ps_protocol
 }
-SELECT * FROM test.v1;
+SELECT * FROM test.v1 ORDER BY f59,f60,f61 LIMIT 2;
 --enable_ps_protocol
 Drop view test.v1 ;
 
@@ -880,8 +880,8 @@ let $message= Testcase 3.3.1.16 + 3.3.1.
 Drop table if exists test.v1 ;
 --enable_warnings
 CREATE OR REPLACE VIEW v1 AS SELECT * From tb2;
-# Note(ML): The empty result is intended, because I want to compare
-#           column names only
+# Note(mleich): The empty result is intended, because I want to compare
+#               column names only.
 SELECT * FROM tb2 WHERE 1 = 2;
 SELECT * FROM v1  WHERE 1 = 2;
 Drop view v1;
@@ -924,7 +924,7 @@ let $message= Testcase 3.3.1.18 ;
 #                    from the underlying base table(s) rather than the view
 #                    column names.
 ###############################################################################
-# Note(ML): The goal is to check the merge algorithm.
+# Note(mleich): The goal is to check the merge algorithm.
 --disable_warnings
 Drop view if exists v1 ;
 Drop view if exists v1_1 ;
@@ -935,14 +935,14 @@ from test.tb2 limit 0,100 ;
 Create view v1_1
 as Select test.tb2.f59 as NewNameF1, test.tb2.f60 as NewNameF2
 from tb2 limit 0,100 ;
---error 1054
+--error ER_BAD_FIELD_ERROR
 SELECT NewNameF1,f60             FROM test.v1_1 ;
---error 1054
+--error ER_BAD_FIELD_ERROR
 SELECT NewNameF1, v1_1.f60 FROM test.v1_1 ;
---error 1054
+--error ER_BAD_FIELD_ERROR
 SELECT f59, f60 FROM test.v1 ;
 Use test ;
---error 1054
+--error ER_BAD_FIELD_ERROR
 SELECT F59 FROM v1 ;
 
 
@@ -974,14 +974,14 @@ SELECT * FROM v1;
 # negative testcases (sometimes including the underlying SELECT)
 # duplicate via alias in SELECT
 SELECT f1, f2 AS f1 FROM t1;
---error 1060
+--error ER_DUP_FIELDNAME
 CREATE OR REPLACE VIEW v1 AS SELECT f1, f2 AS f1 FROM t1;
 # duplicate via JOIN SELECT
 SELECT t1.f1, t2.f1 AS f1 FROM t1, t2;
---error 1060
+--error ER_DUP_FIELDNAME
 CREATE OR REPLACE VIEW v1 AS SELECT t1.f1, t2.f1 AS f1 FROM t1, t2;
 # duplicate via VIEW definition
---error 1060
+--error ER_DUP_FIELDNAME
 CREATE OR REPLACE VIEW v1 (my_col, my_col) AS SELECT * FROM t1;
 
 
@@ -1000,13 +1000,13 @@ CREATE TABLE t1( f1 BIGINT, f2 DECIMAL(5
 CREATE OR REPLACE VIEW v1 (my_f1, my_f2) AS SELECT *      FROM t1;
 CREATE OR REPLACE VIEW v1 (my_f1, my_f2) AS SELECT f1, f2 FROM t1;
 # negative cases, where we assign a wrong number of column names
---error 1353
+--error ER_VIEW_WRONG_LIST
 CREATE OR REPLACE VIEW v1 (my_f1       ) AS SELECT *      FROM t1;
---error 1353
+--error ER_VIEW_WRONG_LIST
 CREATE OR REPLACE VIEW v1 (my_f1       ) AS SELECT f1, f2 FROM t1;
---error 1353
+--error ER_VIEW_WRONG_LIST
 CREATE OR REPLACE VIEW v1 (my_f1, my_f2, my_f3) AS SELECT *      FROM t1;
---error 1353
+--error ER_VIEW_WRONG_LIST
 CREATE OR REPLACE VIEW v1 (my_f1, my_f2, my_f3) AS SELECT f1, f2 FROM t1;
 
 
@@ -1019,8 +1019,8 @@ let $message= Testcase 3.3.1.21 ;
 --disable_warnings
 DROP VIEW  IF EXISTS v1;
 --enable_warnings
-CREATE VIEW test.v1( F59, F60 ) AS SELECT F59, F60 From tb2 LIMIT 2;
-SELECT * FROM test.v1 order by F59, F60 desc;
+CREATE VIEW test.v1( F59, F60 ) AS SELECT F59, F60 From tb2;
+SELECT * FROM test.v1 order by F59, F60 desc LIMIT 2;
 Drop view if exists test.v1 ;
 
 
@@ -1034,12 +1034,12 @@ let $message= Testcase 3.3.1.22 ;
 --disable_warnings
 DROP VIEW  IF EXISTS v1;
 --enable_warnings
-CREATE VIEW test.v1( product ) AS SELECT f59*f60 From tb2 LIMIT 2;
-SELECT * FROM test.v1;
+CREATE VIEW test.v1( product ) AS SELECT f59*f60 From tb2;
+SELECT * FROM test.v1 WHERE product IS NOT NULL ORDER BY product LIMIT 2;
 CREATE OR REPLACE VIEW test.v1( product ) AS SELECT 1*2;
-SELECT * FROM test.v1;
+SELECT * FROM test.v1 LIMIT 2;
 CREATE OR REPLACE VIEW test.v1( product ) AS SELECT USER();
-SELECT * FROM test.v1;
+SELECT * FROM test.v1 LIMIT 2;
 Drop view if exists test.v1 ;
 
 
@@ -1053,18 +1053,18 @@ let $message= Testcase 3.3.1.23 + 3.3.1.
 #                    a non-existent view fails, with an appropriate error
 #                    message, at creation time.
 ###############################################################################
-# Note(ML): The SELECT statement syntax does not contain any functionality to
-#           claim, that the object after FROM must be a VIEW.
-#           Testcase 3.3.1.24 should be deleted.
+# Note(mleich): The SELECT statement syntax does not contain any functionality
+#               to claim, that the object after FROM must be a VIEW.
+#               Testcase 3.3.1.24 should be deleted.
 USE test;
 --disable_warnings
 DROP TABLE IF EXISTS t1;
 DROP VIEW  IF EXISTS v1;
 DROP VIEW  IF EXISTS v2;
 --enable_warnings
---error 1146
+--error ER_NO_SUCH_TABLE
 CREATE VIEW test.v2 AS SELECT * FROM test.t1;
---error 1146
+--error ER_NO_SUCH_TABLE
 CREATE VIEW      v2 AS Select * from test.v1;
 DROP VIEW IF EXISTS v2;
 
@@ -1075,8 +1075,8 @@ let $message= Testcase 3.3.1.25 ;
 # Testcase 3.3.1.25: Ensure that a view cannot be based on one or more
 #                    temporary tables.
 ###############################################################################
-# Note(ML): A temporary table hides permanent tables which have the same name.
-#           So do not forget to drop the temporary table.
+# Note(mleich): A temporary table hides permanent tables which have the same
+#               name. So do not forget to drop the temporary table.
 --disable_warnings
 DROP TABLE IF EXISTS t1_temp;
 DROP TABLE IF EXISTS t2_temp;
@@ -1086,13 +1086,13 @@ Create table t1_temp(f59 char(10),f60 in
 Create temporary table t1_temp(f59 char(10),f60 int) ;
 Insert into t1_temp values('FER',90);
 Insert into t1_temp values('CAR',27);
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 Create view v1 as select * from t1_temp ;
 
 Create temporary table t2_temp(f59 char(10),f60 int) ;
 Insert into t2_temp values('AAA',11);
 Insert into t2_temp values('BBB',22);
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 Create or replace view v1
 as select t1_temp.f59,t2_temp.f59 from t1_temp,t2_temp ;
 DROP temporary table t1_temp;
@@ -1110,34 +1110,34 @@ INSERT INTO t1 VALUES('A');
 INSERT INTO t2 VALUES('t2');
 INSERT INTO t2 VALUES('B');
 # simple SELECT
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 CREATE OR REPLACE VIEW v1 AS SELECT f2 FROM t2;
 # JOIN - temporary table first
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 CREATE OR REPLACE VIEW v1 AS SELECT *      FROM t2, t1;
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 CREATE OR REPLACE VIEW v1 AS SELECT f2, f1 FROM t2, t1;
 # JOIN - temporary table last
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 CREATE OR REPLACE VIEW v1 AS SELECT *      FROM t1, t2;
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 CREATE OR REPLACE VIEW v1 AS SELECT f1, f2 FROM t1, t2;
 # UNION - temporary table first
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 CREATE OR REPLACE VIEW v1 AS SELECT *  FROM t2 UNION SELECT *  FROM t1;
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 CREATE OR REPLACE VIEW v1 AS SELECT f2 FROM t2 UNION SELECT f1 FROM t1;
 # UNION - temporary table last
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 CREATE OR REPLACE VIEW v1 AS SELECT *  FROM t1 UNION SELECT *  FROM t2;
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 CREATE OR REPLACE VIEW v1 AS SELECT f1 FROM t1 UNION SELECT f2 FROM t2;
 # SUBQUERY - temporary table first
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 CREATE OR REPLACE VIEW v1 AS SELECT 1 FROM t2
 WHERE f2 = ( SELECT f1 FROM t1 );
 # SUBQUERY - temporary table last
---error 1352
+--error ER_VIEW_SELECT_TMPTABLE
 CREATE OR REPLACE VIEW v1 AS SELECT 1 FROM t1
 WHERE f1 = ( SELECT f2 FROM t2 );
 DROP TABLE t1;
@@ -1153,12 +1153,12 @@ let $message= Testcase 3.3.1.26 ;
 --disable_warnings
 DROP VIEW  IF EXISTS v1;
 --enable_warnings
-Create view test.v1 AS Select * from test.tb2 limit 2 ;
+Create view test.v1 AS Select * from test.tb2;
 if ($have_bug_11589)
 {
 --disable_ps_protocol
 }
-Select * from test.v1;
+Select * from test.v1 order by f59, f60, f61 limit 2;
 --enable_ps_protocol
 Drop view test.v1 ;
 
@@ -1173,9 +1173,9 @@ let $message= Testcase 3.3.1.27 ;
 DROP VIEW  IF EXISTS test.v1;
 Drop VIEW  IF EXISTS test.v1_1 ;
 --enable_warnings
-Create view test.v1 AS Select * from test.tb2 limit 2 ;
+Create view test.v1 AS Select * from test.tb2;
 Create view test.v1_1 AS Select F59 from test.v1 ;
-Select * from test.v1_1 order by F59 limit 20 ;
+Select * from test.v1_1 order by F59 limit 2;
 Drop view test.v1 ;
 Drop view test.v1_1 ;
 
@@ -1223,7 +1223,8 @@ Create view test2.v2 AS Select F59 from 
 Drop view if exists test.v1 ;
 Drop view if exists test2.v2 ;
 
-# Note(ML): Testcase 3.3.1.30 (identical requirements like 3.3.1.26) omitted
+# Note(mleich): Testcase 3.3.1.30 (identical requirements like 3.3.1.26)
+#               --> omitted
 
 let $message= Testcase 3.3.1.31 ;
 --source include/show_msg80.inc
@@ -1372,10 +1373,6 @@ let $message= Testcase 3.3.1.37 ;
 #                    tables and/or views, some of which reside in the same
 #                    database and some of which reside in one other database.
 ###############################################################################
-# (Bug Associated)
-# FIXME: ??? Bug number
-# FIXME: reimplement this test
-
 use test;
 --disable_warnings
 Drop table if exists t1;
@@ -1407,8 +1404,8 @@ Drop view  test.v1_main ;
 let $message= Testcase 3.3.1.31 - 3.3.1.37 New Implementation ;
 --source include/show_msg80.inc
 ###############################################################################
-# ML: The testcases 3.3.1.31 - 3.3.1.37 should be tested more systematic.
-#                  Ensure that a view can be based on a join of multiple
+# mleich: The testcases 3.3.1.31 - 3.3.1.37 should be tested more systematic.
+#                       Ensure that a view can be based on a join of multiple
 # Testcase 3.3.1.31:        tables              within the same database
 # Testcase 3.3.1.32:        tables              from another    database.
 # Testcase 3.3.1.33:        views               within the same database
@@ -1504,8 +1501,8 @@ Drop view  if exists test.v1_main;
 Drop view  if exists test1.v1_1 ;
 Drop database if exists test3 ;
 --enable_warnings
-Create view test.v1 as Select f59, f60 FROM test.tb2 limit 20 ;
-Select * from test.v1 order by f59,f60;
+Create view test.v1 as Select f59, f60 FROM test.tb2;
+Select * from test.v1 order by f59,f60 limit 20;
 
 Create table test1.t1 (f59 int,f60 int)  ;
 Insert into test1.t1 values (199,507) ;
@@ -1522,7 +1519,7 @@ Create view test3.v1_2 as Select f59,f60
 Select * from test3.v1_2 ;
 use test ;
 
-# ML: FIXME The SELECT should deliver at least one row.
+# mleich: FIXME The SELECT should deliver at least one row.
 Create view v1_main
 as SELECT test.tb2.f59 as f1, test1.v1_1.f59 as f2,
           test3.v1_2.f59 as f3
@@ -1546,10 +1543,10 @@ let $message= Testcase 3.3.1.39 ;
 --disable_warnings
 Drop view if exists test.v1 ;
 --enable_warnings
---error 1349
+--error ER_VIEW_SELECT_DERIVED
 CREATE VIEW test.v1
 AS Select f59 from (Select * FROM tb2 limit 20) tx ;
---error 1146
+--error ER_NO_SUCH_TABLE
 SELECT * FROM test.v1 order by f59 ;
 --disable_warnings
 Drop view if exists test.v1 ;
@@ -1568,10 +1565,10 @@ Drop view if exists test.v1 ;
 --enable_warnings
 Set @var1 = 'ABC' ;
 Set @var2 = 'XYZ' ;
---error 1351
+--error ER_VIEW_SELECT_VARIABLE
 CREATE VIEW test.v1 AS SELECT @var1, @var2 ;
 # System variables (name starts with '@@') are also not allowed
---error 1351
+--error ER_VIEW_SELECT_VARIABLE
 CREATE VIEW test.v1 AS SELECT @@global.sort_buffer_size;
 --disable_warnings
 Drop view if exists test.v1 ;
@@ -1616,11 +1613,11 @@ let $message= Testcase 3.3.1.42 ;
 --disable_warnings
 Drop VIEW if exists test.v1 ;
 --enable_warnings
---error 1064
+--error ER_PARSE_ERROR
 CREATE TEMPORARY VIEW test.v1 AS
 SELECT * FROM test.tb2 limit 2 ;
 #(02)
---error 1064
+--error ER_PARSE_ERROR
 CREATE OR REPLACE TEMPORARY VIEW test.v1 AS
 SELECT * FROM test.tb2 limit 2 ;
 
@@ -1677,12 +1674,12 @@ let $message= Testcase 3.3.1.44 ;
 #                    with an appropriate error message and do not affect the
 #                    data in the underlying tables(s).
 ###############################################################################
-# ML: Maybe we need some more tests here.
+# mleich: Maybe we need some more tests here.
 --disable_warnings
 Drop view if exists test.v1 ;
 --enable_warnings
 
-# Note(ML): The modification will fail, because the VIEW contains 'limit'
+# Note(mleich): The modification will fail, because the VIEW contains 'limit'
 CREATE VIEW test.v1 AS SELECT f59,f60 FROM test.tb2 limit 100;
 
 --error ER_NON_INSERTABLE_TABLE
@@ -1819,7 +1816,7 @@ Drop view if exists test.v1 ;
 CREATE VIEW test.v1 AS SELECT f59,f60
 FROM test.tb2 where f59 = 195 WITH CHECK OPTION ;
 
---error 1369
+--error ER_VIEW_CHECK_FAILED
 UPDATE test.v1 SET f59 = 198 where f59=195 ;
 SELECT * FROM test.v1 order by f59 ;
 
@@ -1844,14 +1841,14 @@ FROM test.tb2 where F59 = 0987 WITH LOCA
 CREATE VIEW test.v2 as SELECT * FROM test.v1 ;
 
 # This UPDATE violates the definition of VIEW test.v1.
---error 1369
+--error ER_VIEW_CHECK_FAILED
 UPDATE test.v1 SET F59 = 919 where f59 = 0987 ;
 SELECT * FROM test.v1 order by f59 ;
 
-# ML: This UPDATE violates the definition of VIEW test.v1, but this
-#     does not count, because the UPDATE runs on test.v2, which
-#     is defined without any CHECK OPTION.
-#     FIXME Does this testcase fit to 3.3.1.47 ?
+# mleich: This UPDATE violates the definition of VIEW test.v1, but this
+#         does not count, because the UPDATE runs on test.v2, which
+#         is defined without any CHECK OPTION.
+#         FIXME Does this testcase fit to 3.3.1.47 ?
 UPDATE test.v2 SET F59 = 9879 where f59 = 919 ;
 SELECT * FROM tb2 where f59 = 9879 ;
 
@@ -1890,9 +1887,9 @@ INSERT INTO v1 VALUES('B',2);
 SELECT * FROM v1 order by f1, f2;
 # negative cases
 --enable_info
---error 1369
+--error ER_VIEW_CHECK_FAILED
 UPDATE v1 SET f2 = 4;
---error 1369
+--error ER_VIEW_CHECK_FAILED
 INSERT INTO v1 VALUES('B',3);
 --disable_info
 # Bug#11771: View over InnoDB table, wrong result SELECT on VIEW,
@@ -2272,7 +2269,8 @@ SELECT * FROM t1_results
 WHERE v3_to_v1_options LIKE 'WITH %' AND v3_to_v1_options NOT LIKE 'WITH LOCAL %'
   AND v3_to_v1_violation NOT LIKE '  _  _  ' AND errno = 0
 ORDER BY v3_to_v1_options;
-# 5. There must be NO failing INSERT/UPDATE getting a sql_errno <> 1369.
+# 5. There must be NO failing INSERT/UPDATE getting a
+#    sql_errno <> 1369 (ER_VIEW_CHECK_FAILED).
 SELECT * FROM t1_results
 WHERE errno <> 0 AND errno <> 1369
 ORDER BY v3_to_v1_options;
@@ -2294,12 +2292,12 @@ DROP VIEW  IF EXISTS test.v1;
 #                    that is semantically equivalent to CREATE VIEW <view name>
 #                    AS SELECT * FROM <table name>.
 ###############################################################################
-CREATE VIEW test.v1 AS SELECT * FROM test.tb2 limit 5 ;
+CREATE VIEW test.v1 AS SELECT * FROM test.tb2;
 if ($have_bug_11589)
 {
 --disable_ps_protocol
 }
-SELECT * FROM test.v1 order by f59 ;
+SELECT * FROM test.v1 order by f59 limit 5;
 --enable_ps_protocol
 drop view test.v1 ;
 ###############################################################################
@@ -2309,8 +2307,8 @@ drop view test.v1 ;
 #                    that is semantically equivalent to CREATE VIEW <view name>
 #                    AS SELECT col1, col3 FROM <table name>.
 ###############################################################################
-CREATE VIEW test.v1 AS SELECT F59,F61 FROM test.tb2 limit 50 ;
-SELECT * FROM test.v1 order by F59, F61 ;
+CREATE VIEW test.v1 AS SELECT F59,F61 FROM test.tb2;
+SELECT * FROM test.v1 order by F59, F61 limit 50;
 drop view test.v1 ;
 ###############################################################################
 # Testcase 3.3.1.52: Ensure that a view that is a subset of every column and
@@ -2319,12 +2317,12 @@ drop view test.v1 ;
 #                    that is semantically equivalent to CREATE VIEW <view name>
 #                    AS SELECT * FROM <table name> WHERE ....
 ###############################################################################
-CREATE VIEW test.v1 AS SELECT * FROM test.tb2 order by f59, f60, f61 limit 20 ;
+CREATE VIEW test.v1 AS SELECT * FROM test.tb2 order by f59, f60, f61;
 if ($have_bug_11589)
 {
 --disable_ps_protocol
 }
-SELECT * FROM test.v1 order by f59,f60,f61 ;
+SELECT * FROM test.v1 order by f59,f60,f61 limit 20;
 --enable_ps_protocol
 drop view test.v1 ;
 ###############################################################################
@@ -2334,8 +2332,8 @@ drop view test.v1 ;
 #                    definition that is semantically equivalent to CREATE VIEW
 #                    <view name> AS SELECT col1, col3 FROM <table name> WHERE ..
 ###############################################################################
-CREATE VIEW test.v1 AS SELECT F59,f61 FROM test.tb2 limit 20 ;
-SELECT * FROM test.v1 order by f59,f61 desc limit 50;
+CREATE VIEW test.v1 AS SELECT F59,f61 FROM test.tb2;
+SELECT * FROM test.v1 order by f59,f61 desc limit 20;
 drop view test.v1 ;
 
 
@@ -2370,10 +2368,10 @@ drop table test.t2 ;
 drop view  test.v1 ;
 
 
-# FIXME(ML): Implement an automatic check for 3.3.1.50 - 3.3.1.54
-#            CREATE VIEW ... AS <SELECT ... FROM tb2 ...>
-#            CREATE TEMPORARY TABLE ... AS <SELECT ... FROM tb2 ...>
-#            Comparison of the VIEW with the temporary table
+# FIXME(mleich): Implement an automatic check for 3.3.1.50 - 3.3.1.54
+#                CREATE VIEW ... AS <SELECT ... FROM tb2 ...>
+#                CREATE TEMPORARY TABLE ... AS <SELECT ... FROM tb2 ...>
+#                Comparison of the VIEW with the temporary table
 
 let $message= Testcase 3.3.1.50 - 3.3.1.54 additional implementation;
 --source include/show_msg80.inc
@@ -2704,7 +2702,7 @@ CREATE VIEW  v1 AS SELECT f1 FROM t1;
 
 # DROP VIEW
 DROP VIEW v1;
---error 1051
+--error ER_BAD_TABLE_ERROR
 DROP VIEW v1;
 
 CREATE VIEW  v1 AS SELECT f1 FROM t1;
@@ -2751,7 +2749,7 @@ while ($num1)
   # DROP VIEW v1_top < |RESTRICD|CASCADE> must be successful.
   eval $aux1 ;
   # Check, that v1_top really no more exists + cleanup for the second sub test
-  --error 1051
+  --error ER_BAD_TABLE_ERROR
   DROP VIEW v1_top;
 
   CREATE VIEW  v1_top AS SELECT * FROM v1_base;
@@ -2781,8 +2779,8 @@ let $message= Testcase 3.3.1.69, 3.3.1.7
 # 3.3.1.A5    SHOW COLUMNS, SHOW FIELDS, DESCRIBE, EXPLAIN
 #             statement is executed
 ###############################################################################
-# Note(ML): There will be no non failing sub testcases with SHOW here.
-#           They will be done in 3.3.11 ff.
+# Note(mleich): There will be no non failing sub testcases with SHOW here.
+#               They will be done in 3.3.11 ff.
 --disable_warnings
 DROP TABLE IF EXISTS t1 ;
 DROP VIEW  IF EXISTS v1 ;
@@ -2793,24 +2791,24 @@ DROP VIEW v1 ;
 
 # The negative tests:
 #     SELECT
---error 1146
+--error ER_NO_SUCH_TABLE
 SELECT * FROM v1 ;
 #
---error 1146
+--error ER_NO_SUCH_TABLE
 SHOW CREATE VIEW v1 ;
---error 1146
+--error ER_NO_SUCH_TABLE
 SHOW CREATE TABLE v1 ;
 # Attention: Like is a filter. So we will get an empty result set here.
 SHOW TABLE STATUS like 'v1' ;
 SHOW TABLES LIKE 'v1';
---error 1146
+--error ER_NO_SUCH_TABLE
 SHOW COLUMNS FROM v1;
---error 1146
+--error ER_NO_SUCH_TABLE
 SHOW FIELDS  FROM v1;
 CHECK TABLE v1;
---error 1146
+--error ER_NO_SUCH_TABLE
 DESCRIBE v1;
---error 1146
+--error ER_NO_SUCH_TABLE
 EXPLAIN SELECT * FROM v1;
 
 Use test;
@@ -2879,9 +2877,9 @@ eval EXPLAIN SELECT * FROM test3.v$tople
 # 1.2 Check the top level view when a base VIEW is dropped
 DROP VIEW test3.v0;
 eval SHOW CREATE VIEW test3.v$toplevel;
---error 1356
+--error ER_VIEW_INVALID
 eval SELECT * FROM test3.v$toplevel;
---error 1356
+--error ER_VIEW_INVALID
 eval EXPLAIN SELECT * FROM test3.v$toplevel;
 
 
@@ -2894,10 +2892,10 @@ eval EXPLAIN SELECT * FROM test3.v$tople
 #++++++++++++++++++++++++++++++++++++++++++++++
 # OBN - Reduced the value of join limit to 30
 #       Above seems to hang - FIXME
-# ML  - Reason unclear why it hangs for OBN on innodb and memory.
-#       Hypothesis: Maybe the consumption of virtual memory is high
-#                   and OBN's box performs excessive paging.
-#                   (RAM: OBN ~384MB RAM, ML 1 GB)
+# mleich  - Reason unclear why it hangs for OBN on innodb and memory.
+#           Hypothesis: Maybe the consumption of virtual memory is high
+#                       and OBN's box performs excessive paging.
+#                       (RAM: OBN ~384MB RAM, mleich 1 GB)
 #++++++++++++++++++++++++++++++++++++++++++++++
 let $message= FIXME - Setting join_limit to 28 - hangs for higher values;
 --source include/show_msg.inc
@@ -3042,9 +3040,9 @@ let $sublevel= `SELECT @max_level`;
 eval CREATE VIEW test1.v$level AS SELECT f1, f2
             FROM test3.t1 tab1 NATURAL JOIN test1.v$sublevel tab2;
 eval SHOW CREATE VIEW test1.v$level;
-# the following line as written as '--eror 1116' and the command
+# the following line as written as '--eror ER_TOO_MANY_TABLES' and the command
 # is successful so assuming no expected error was intended
-# --error 1116
+# --error ER_TOO_MANY_TABLES
 eval SELECT CAST(f1 AS SIGNED INTEGER) AS f1,
             CAST(f2 AS CHAR) AS f2 FROM test1.v$level;
 let $message= The output of following EXPLAIN is deactivated, because the result
@@ -3055,9 +3053,9 @@ if (1)
 {
 --disable_result_log
 }
-# the following line as written as '--eror 1116' and the command
+# the following line as written as '--eror ER_TOO_MANY_TABLES' and the command
 # is successful so assuming no expected error was intended
-# --error 1116
+# --error ER_TOO_MANY_TABLES
 eval EXPLAIN SELECT CAST(f1 AS SIGNED INTEGER) AS f1,
                 CAST(f2 AS CHAR) AS f2 FROM test1.v$level;
 if (1)
@@ -3536,25 +3534,25 @@ DELETE FROM t1;
 #------------------------------------------------
 INSERT INTO t1 VALUES(1, 'ABC', -1.2E-3, 'X');
 # UPDATE my_greeting - f1
---error 1348
+--error ER_NONUPDATEABLE_COLUMN
 UPDATE v1 SET my_greeting = 'Hej' WHERE f1 = 1;
 SELECT * from t1;
 DELETE FROM t1;
 INSERT INTO t1 VALUES(1, 'ABC', -1.2E-3, 'X');
 # UPDATE my_greeting - f2
---error 1348
+--error ER_NONUPDATEABLE_COLUMN
 UPDATE v1 SET my_greeting = 'Hej' WHERE f2 = 'ABC';
 SELECT * from t1;
 DELETE FROM t1;
 INSERT INTO t1 VALUES(1, 'ABC', -1.2E-3, 'X');
 # UPDATE my_greeting - my_greeting
---error 1348
+--error ER_NONUPDATEABLE_COLUMN
 UPDATE v1 SET my_greeting = 'Hej' WHERE my_greeting = 'HELLO';
 SELECT * from t1;
 DELETE FROM t1;
 INSERT INTO t1 VALUES(1, 'ABC', -1.2E-3, 'X');
 # UPDATE my_greeting - none
---error 1348
+--error ER_NONUPDATEABLE_COLUMN
 UPDATE v1 SET my_greeting = 'Hej';
 SELECT * from t1;
 DELETE FROM t1;
@@ -3577,7 +3575,7 @@ DROP VIEW v1;
 CREATE VIEW v1 AS SELECT f1, f2, f4 FROM t1;
 
 # This INSERT must fail
---error 1423
+--error ER_NO_DEFAULT_FOR_VIEW_FIELD
 INSERT INTO v1 SET f1 = 1;
 SELECT * from t1;
 DELETE FROM t1;
@@ -3633,7 +3631,7 @@ let $message= Testcases 3.3.2.7 - 3.3.2.
 #        rejects any INSERT or UPDATE or DELETE statement with an 
 #        appropriate error message
 #
-# ML: I assume the type of the storage engine does not play any role.
+# mleich: I assume the type of the storage engine does not play any role.
 ###############################################################################
 INSERT INTO tb2 (f59,f60,f61) VALUES (77,185,126) ;
 INSERT INTO tb2 (f59,f60,f61) VALUES (59,58,54) ;
@@ -3668,9 +3666,9 @@ while ($num)
    eval $aux;
    --error ER_NON_INSERTABLE_TABLE
    INSERT INTO v1 VALUES (3000);
-   --error 1288
+   --error ER_NON_UPDATABLE_TABLE
    UPDATE v1 SET f61 = 100 WHERE f61 = 32;
-   --error 1288
+   --error ER_NON_UPDATABLE_TABLE
    DELETE FROM v1;
    DROP VIEW v1 ;
 
@@ -3771,11 +3769,15 @@ SET @variant7= 'CREATE VIEW v1 AS SELECT
 #            but the error message
 #                ERROR 1093 (HY000) : You can't specify target table 'v1' for
 #                update in FORM clause"
-#            is wrong. The server must deliver ERROR 1288.
+#            is wrong.
+#            The server must deliver ERROR 1288 (ER_NON_UPDATABLE_TABLE).
 #            Bug#10773 Incorrect message is displayed while updating a view
-# ML FIXME (remove the comment above, replace --error 1288,1093 with 
-#    --error 1288 and update the file with expected results)
-#    when Bug#10773 is solved
+# mleich FIXME: Remove the comment above, replace
+#                  --error ER_NON_UPDATABLE_TABLE,ER_UPDATE_TABLE_USED
+#               with
+#                  --error ER_NON_UPDATABLE_TABLE
+#               and update the file with expected results when the
+#               Bug#10773 is fixed.
 # For a reference to a non-updateable view 3.3.2.19
 let $message= Some server responses suffer from 
 Bug#10773 Incorrect message is displayed while updating a view;
@@ -3798,15 +3800,12 @@ while ($num)
 
    --error ER_NON_INSERTABLE_TABLE
    INSERT INTO v1 VALUES (1002);
-   --error 1288, 1093
+   # --error ER_NON_UPDATABLE_TABLE, ER_UPDATE_TABLE_USED
+   --error ER_NON_UPDATABLE_TABLE
    UPDATE v1 SET f61=1007;
-   --error 1288
+   --error ER_NON_UPDATABLE_TABLE
    DELETE FROM v1;
 
-   # The following "--error 0" will be no more needed, when 
-   #    Bug#12471: mysqltest, --error within loop affects wrong statement
-   # is fixed.
-   --error 0
    DROP VIEW v1;
 
    dec $num;
@@ -3852,18 +3851,18 @@ SELECT * FROM v1 order by f1, report;
 # 1. Name of one base table column is altered
 ALTER TABLE t1 CHANGE COLUMN f4 f4x CHAR(5);
 INSERT INTO t1 SET f1 = 0, f4x = 'ABC', report = 't1 1';
---error 1356
+--error ER_VIEW_INVALID
 INSERT INTO v1 SET f1 = 0, f4  = 'ABC', report = 'v1 1';
---error 1054
+--error ER_BAD_FIELD_ERROR
 INSERT INTO v1 SET f1 = 0, f4x = 'ABC', report = 'v1 1a';
---error 1356
+--error ER_VIEW_INVALID
 INSERT INTO v1 SET f1 = 0, report = 'v1 1b';
 DESCRIBE t1;
 # Bug#12533 crash on DESCRIBE <view> after renaming base table column;
---error 1356
+--error ER_VIEW_INVALID
 DESCRIBE v1;
 SELECT * FROM t1 order by f1, report;
---error 1356
+--error ER_VIEW_INVALID
 SELECT * FROM v1 order by f1, report;
 ALTER TABLE t1 CHANGE COLUMN f4x f4 CHAR(5);
 #
@@ -3908,13 +3907,13 @@ SELECT * FROM v1 order by f1, report;
 # 6. DROP of one base table column
 ALTER TABLE t1 DROP COLUMN f2;
 INSERT INTO t1 SET f1 = 'ABC', f4 = '<------ 20 -------->', report = 't1 6';
---error 1356
+--error ER_VIEW_INVALID
 INSERT INTO v1 SET f1 = 'ABC', f4 = '<------ 20 -------->', report = 'v1 6';
 DESCRIBE t1;
---error 1356
+--error ER_VIEW_INVALID
 DESCRIBE v1;
 SELECT * FROM t1 order by f1, report;
---error 1356
+--error ER_VIEW_INVALID
 SELECT * FROM v1 order by f1, report;
 #
 # 7. Recreation of dropped base table column with the same data type like before
@@ -3945,7 +3944,7 @@ SELECT * FROM v1 order by f1, report;
 ALTER TABLE t1 ADD COLUMN f3 NUMERIC(7,2);
 INSERT INTO t1 SET f1 = 'ABC', f2 = -3.3E-4,
                    f3 = -2.2, f4 = '<------ 20 -------->', report = 't1 9';
---error 1054
+--error ER_BAD_FIELD_ERROR
 INSERT INTO v1 SET f1 = 'ABC', f2 = -3.3E-4,
                    f3 = -2.2, f4 = '<------ 20 -------->', report = 'v1 9';
 INSERT INTO v1 SET f1 = 'ABC', f2 = -3.3E-4,
Thread
bk commit into 5.1 tree (mleich:1.2574) BUG#31237mleich5 Oct