403Webshell
Server IP : 45.40.142.9  /  Your IP : 216.73.216.250
Web Server : Apache
System : Linux s45-40-142-9.secureserver.net 2.6.32-754.35.1.el6.x86_64 #1 SMP Sat Nov 7 12:42:14 UTC 2020 x86_64
User : bayspec ( 506)
PHP Version : 5.6.40
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/share/mysql-test/suite/ndb/t/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/share/mysql-test/suite/ndb/t/ndb_row_format.test
-- source include/have_ndb.inc

--disable_warnings
DROP TABLE IF EXISTS t1,t2,t3,t4,t5,t6,t7;
drop database if exists mysqltest;
--enable_warnings

#
# some negative tests
#

# cannot have ROW_FORMAT=FIXED and var attrs mixed
CREATE TABLE t1
  ( a INT KEY,
    b VARCHAR(10) )
  ROW_FORMAT=FIXED
  ENGINE=NDB;

# warnings give more detail on the conflict
SHOW WARNINGS;
source show_varpart.inc;
INSERT INTO t1 values(0,''),(2,"**"),(4,"****"),(6,"******"),(8,"********"),(10,"**********"),(12,"************");
SELECT * FROM t1 ORDER BY a;
DROP TABLE t1;

#
# Check force var part for different ROW_FORMAT
#

# default => ForceVarPart: 1
CREATE TABLE t1
  ( a INT KEY,
    b INT )
  ENGINE=NDB;
source show_varpart.inc;
DROP TABLE t1;

# explicit DEFAULT => ForceVarPart: 1
CREATE TABLE t1
  ( a INT KEY,
    b INT )
  ROW_FORMAT=DEFAULT
  ENGINE=NDB;
source show_varpart.inc;
DROP TABLE t1;

# FIXED => ForceVarPart: 0
CREATE TABLE t1
  ( a INT KEY,
    b INT )
  ROW_FORMAT=FIXED
  ENGINE=NDB;
source show_varpart.inc;
DROP TABLE t1;

# DYNAMIC => ForceVarPart: 1
CREATE TABLE t1
  ( a INT KEY,
    b INT )
  ROW_FORMAT=DYNAMIC
  ENGINE=NDB;
source show_varpart.inc;
DROP TABLE t1;

# test of bug
create table t1 (a int auto_increment primary key, b varchar(1000)) engine = ndb;
insert into t1(b) values ('0123456789');
insert into t1(b) select b from t1;
insert into t1(b) select b from t1;
insert into t1(b) select b from t1;
insert into t1(b) select b from t1;
insert into t1(b) select b from t1;
insert into t1(b) select b from t1;
insert into t1(b) select b from t1;
insert into t1(b) select b from t1;
insert into t1(b) select b from t1;
insert into t1(b) select b from t1;
select count(*) from t1;
begin;
update t1 set b = concat(b,b);
update t1 set b = concat(b,b);
update t1 set b = concat(b,b);
update t1 set b = concat(b,b);
update t1 set b = concat(b,b);
rollback;
select count(*),b from t1 group by b;
drop table t1;

Youez - 2016 - github.com/yon3zu
LinuXploit