1# Copyright(C) 2010 Tetsuro IKEDA
2# Copyright(C) 2016-2017 Kouhei Sutou <kou@clear-code.com>
3#
4# This library is free software; you can redistribute it and/or
5# modify it under the terms of the GNU Lesser General Public
6# License as published by the Free Software Foundation; either
7# version 2.1 of the License, or (at your option) any later version.
8#
9# This library is distributed in the hope that it will be useful,
10# but WITHOUT ANY WARRANTY; without even the implied warranty of
11# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12# Lesser General Public License for more details.
13#
14# You should have received a copy of the GNU Lesser General Public
15# License along with this library; if not, write to the Free Software
16# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1335  USA
17
18--source ../../include/mroonga/skip_strict_sql_mode.inc
19--source ../../include/mroonga/have_mroonga.inc
20
21--disable_warnings
22DROP TABLE IF EXISTS t1;
23--enable_warnings
24
25CREATE TABLE t1 (_id int, a int, PRIMARY KEY (_id) USING HASH);
26
27--error ER_BAD_NULL_ERROR
28INSERT INTO t1 VALUES(null, 100);
29INSERT INTO t1 VALUES(1,100);
30INSERT INTO t1 VALUES(1,100);
31INSERT INTO t1 VALUES(1,100);
32INSERT INTO t1 VALUES(1,100);
33
34SELECT * FROM t1;
35SELECT * FROM t1 WHERE _id = 2;
36SELECT * FROM t1 WHERE _id = 20;
37
38DROP TABLE t1;
39
40--source ../../include/mroonga/have_mroonga_deinit.inc
41