interp_full.sim 8.7 KB
Newer Older
D
dapan1121 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136
system sh/stop_dnodes.sh
  
system sh/deploy.sh -n dnode1 -i 1
system sh/cfg.sh -n dnode1 -c walLevel -v 1
system sh/cfg.sh -n dnode1 -c minRows -v 10
system sh/exec.sh -n dnode1 -s start
sleep 100
sql connect

sql create database db;
sql use db;
sql create stable stb1 (ts timestamp, c1 int, c2 float, c3 bigint, c4 smallint, c5 tinyint, c6 double, c7 bool, c8 binary(10), c9 nchar(9)) TAGS(t1 int, t2 binary(10), t3 double)
sql create table tb1 using stb1 tags(1,'1',1.0)
sql create table tb2 using stb1 tags(2,'2',2.0)
sql create table tb3 using stb1 tags(3,'3',3.0)
sql create table tb4 using stb1 tags(4,'4',4.0)

sql insert into tb1 values ('2021-10-20 10:00:00',0,0.0,0,0,0,0.0,true ,'0','0')
sql insert into tb1 values ('2021-10-20 10:00:01',1,1.0,1,1,1,1.0,true ,'1','1')
sql insert into tb1 values ('2021-10-20 10:00:03',3,3.0,3,3,3,3.0,false,'3','3')
sql insert into tb1 values ('2021-10-20 10:00:06',6,6.0,6,6,6,6.0,false,'6','6')
sql insert into tb1 values ('2021-10-20 10:00:10',10,10.0,10,10,10,10.0,true ,'10','10')
sql insert into tb1 values ('2021-10-20 10:00:15',15,15.0,15,15,15,15.0,true ,'15','15')
sql insert into tb1 values ('2021-10-20 10:00:21',21,21.0,21,21,21,21.0,false,'21','21')

sql insert into tb2 values ('2021-10-20 10:00:00',0,0.0,0,0,0,0.0,true ,'0','0')
sql insert into tb2 values ('2021-10-20 10:00:02',2,2.0,2,2,2,2.0,true ,'2','2')
sql insert into tb2 values ('2021-10-20 10:00:04',4,4.0,4,4,4,4.0,false,'4','4')
sql insert into tb2 values ('2021-10-20 10:00:06',6,6.0,6,6,6,6.0,false,'6','6')
sql insert into tb2 values ('2021-10-20 10:00:10',10,10.0,10,10,10,10.0,true ,'10','10')
sql insert into tb2 values ('2021-10-20 10:00:12',12,12.0,12,12,12,12.0,true ,'12','12')
sql insert into tb2 values ('2021-10-20 10:00:14',14,14.0,14,14,14,14.0,false,'14','14')

sql insert into tb3 values ('2021-10-20 10:00:00',0,0.0,0,0,0,0.0,true ,'0','0')
sql insert into tb3 values ('2021-10-20 10:00:01',1,1.0,1,1,1,1.0,true ,'1','1')
sql insert into tb3 values ('2021-10-20 10:00:02',2,2.0,2,2,2,2.0,false,'2','2')
sql insert into tb3 values ('2021-10-20 10:00:06',6,6.0,6,6,6,6.0,false,'6','6')
sql insert into tb3 values ('2021-10-20 10:00:10',10,10.0,10,10,10,10.0,true ,'10','10')
sql insert into tb3 values ('2021-10-20 10:00:18',18,18.0,18,18,18,18.0,true ,'18','18')
sql insert into tb3 values ('2021-10-20 10:00:21',21,21.0,21,21,21,21.0,false,'21','21')


sql create stable stb4 (ts timestamp, c1 int, c2 float, c3 bigint, c4 smallint, c5 tinyint, c6 double, c7 bool, c8 binary(10), c9 nchar(9)) TAGS(t1 int, t2 binary(10), t3 double)

sql create table tb4_0 using stb4 tags(0,'0',0.0)
sql create table tb4_1 using stb4 tags(1,'1',1.0)
sql create table tb4_2 using stb4 tags(2,'2',2.0)

sql insert into tb4_0 values ('2021-10-20 10:00:00',0,0.0,0,0,0,0.0,true ,'0','0')
sql insert into tb4_0 values ('2021-10-20 10:00:01',1,1.0,1,1,1,1.0,true ,'1','1')
sql insert into tb4_0 values ('2021-10-20 10:00:03',3,3.0,3,3,3,3.0,false,'3','3')
sql insert into tb4_0 values ('2021-10-20 10:00:06',6,6.0,6,6,6,6.0,false,'6','6')
sql insert into tb4_0 values ('2021-10-20 10:00:10',10,10.0,10,10,10,10.0,true ,'10','10')
sql insert into tb4_0 values ('2021-10-20 10:00:15',15,15.0,15,15,15,15.0,true ,'15','15')
sql insert into tb4_0 values ('2021-10-20 10:00:21',21,21.0,21,21,21,21.0,false,'21','21')
sql insert into tb4_0 values ('2021-10-20 10:00:28',28,28.0,28,28,28,28.0,false,'28','28')
sql insert into tb4_0 values ('2021-10-20 10:00:36',36,36.0,36,36,36,36.0,false,'36','36')
sql insert into tb4_0 values ('2021-10-20 10:00:45',45,45.0,45,45,45,45.0,false,'45','45')
sql insert into tb4_0 values ('2021-10-20 10:00:55',55,55.0,55,55,55,55.0,false,'55','55')

print ================== restart server to commit data into disk
system sh/exec.sh -n dnode1 -s stop -x SIGINT
sleep 500
system sh/exec.sh -n dnode1 -s start
print ================== server restart completed

sql insert into tb4_0 values ('2021-10-20 10:01:00',0,0.0,0,0,0,0.0,true ,'0','0')
sql insert into tb4_0 values ('2021-10-20 10:01:01',1,1.0,1,1,1,1.0,true ,'1','1')
sql insert into tb4_0 values ('2021-10-20 10:01:03',3,3.0,3,3,3,3.0,false,'3','3')
sql insert into tb4_0 values ('2021-10-20 10:01:06',6,6.0,6,6,6,6.0,false,'6','6')
sql insert into tb4_0 values ('2021-10-20 10:01:10',10,10.0,10,10,10,10.0,true ,'10','10')
sql insert into tb4_0 values ('2021-10-20 10:01:15',15,15.0,15,15,15,15.0,true ,'15','15')
sql insert into tb4_0 values ('2021-10-20 10:01:21',21,21.0,21,21,21,21.0,false,'21','21')
sql insert into tb4_0 values ('2021-10-20 10:01:28',28,28.0,28,28,28,28.0,false,'28','28')
sql insert into tb4_0 values ('2021-10-20 10:01:36',36,36.0,36,36,36,36.0,false,'36','36')
sql insert into tb4_0 values ('2021-10-20 10:01:45',45,45.0,45,45,45,45.0,false,'45','45')
sql insert into tb4_0 values ('2021-10-20 10:01:55',55,55.0,55,55,55,55.0,false,'55','55')

print ================== restart server to commit data into disk
system sh/exec.sh -n dnode1 -s stop -x SIGINT
sleep 500
system sh/exec.sh -n dnode1 -s start
print ================== server restart completed

sql insert into tb4_0 values ('2021-10-20 10:02:00',0,0.0,0,0,0,0.0,true ,'0','0')
sql insert into tb4_0 values ('2021-10-20 10:02:01',1,1.0,1,1,1,1.0,true ,'1','1')
sql insert into tb4_0 values ('2021-10-20 10:02:03',3,3.0,3,3,3,3.0,false,'3','3')
sql insert into tb4_0 values ('2021-10-20 10:02:06',6,6.0,6,6,6,6.0,false,'6','6')
sql insert into tb4_0 values ('2021-10-20 10:02:10',10,10.0,10,10,10,10.0,true ,'10','10')
sql insert into tb4_0 values ('2021-10-20 10:02:15',15,15.0,15,15,15,15.0,true ,'15','15')
sql insert into tb4_0 values ('2021-10-20 10:02:21',21,21.0,21,21,21,21.0,false,'21','21')
sql insert into tb4_0 values ('2021-10-20 10:02:28',28,28.0,28,28,28,28.0,false,'28','28')
sql insert into tb4_0 values ('2021-10-20 10:02:36',36,36.0,36,36,36,36.0,false,'36','36')
sql insert into tb4_0 values ('2021-10-20 10:02:45',45,45.0,45,45,45,45.0,false,'45','45')
sql insert into tb4_0 values ('2021-10-20 10:02:55',55,55.0,55,55,55,55.0,false,'55','55')


print ================== restart server to commit data into disk
system sh/exec.sh -n dnode1 -s stop -x SIGINT
sleep 500
system sh/exec.sh -n dnode1 -s start
print ================== server restart completed

sql insert into tb4_0 values ('2021-10-20 10:03:00',0,0.0,0,0,0,0.0,true ,'0','0')
sql insert into tb4_0 values ('2021-10-20 10:03:01',1,1.0,1,1,1,1.0,true ,'1','1')
sql insert into tb4_0 values ('2021-10-20 10:03:03',3,3.0,3,3,3,3.0,false,'3','3')
sql insert into tb4_0 values ('2021-10-20 10:03:06',6,6.0,6,6,6,6.0,false,'6','6')
sql insert into tb4_0 values ('2021-10-20 10:03:10',10,10.0,10,10,10,10.0,true ,'10','10')
sql insert into tb4_0 values ('2021-10-20 10:03:15',15,15.0,15,15,15,15.0,true ,'15','15')
sql insert into tb4_0 values ('2021-10-20 10:03:21',21,21.0,21,21,21,21.0,false,'21','21')
sql insert into tb4_0 values ('2021-10-20 10:03:28',28,28.0,28,28,28,28.0,false,'28','28')
sql insert into tb4_0 values ('2021-10-20 10:03:36',36,36.0,36,36,36,36.0,false,'36','36')
sql insert into tb4_0 values ('2021-10-20 10:03:45',45,45.0,45,45,45,45.0,false,'45','45')
sql insert into tb4_0 values ('2021-10-20 10:03:55',55,55.0,55,55,55,55.0,false,'55','55')


print ================== restart server to commit data into disk
system sh/exec.sh -n dnode1 -s stop -x SIGINT
sleep 500
system sh/exec.sh -n dnode1 -s start
print ================== server restart completed

sql insert into tb4_0 values ('2021-10-20 10:04:00',0,0.0,0,0,0,0.0,true ,'0','0')
sql insert into tb4_0 values ('2021-10-20 10:04:01',1,1.0,1,1,1,1.0,true ,'1','1')
sql insert into tb4_0 values ('2021-10-20 10:04:03',3,3.0,3,3,3,3.0,false,'3','3')
sql insert into tb4_0 values ('2021-10-20 10:04:06',6,6.0,6,6,6,6.0,false,'6','6')
sql insert into tb4_0 values ('2021-10-20 10:04:10',10,10.0,10,10,10,10.0,true ,'10','10')
sql insert into tb4_0 values ('2021-10-20 10:04:15',15,15.0,15,15,15,15.0,true ,'15','15')
sql insert into tb4_0 values ('2021-10-20 10:04:21',21,21.0,21,21,21,21.0,false,'21','21')
sql insert into tb4_0 values ('2021-10-20 10:04:28',28,28.0,28,28,28,28.0,false,'28','28')
sql insert into tb4_0 values ('2021-10-20 10:04:36',36,36.0,36,36,36,36.0,false,'36','36')
sql insert into tb4_0 values ('2021-10-20 10:04:45',45,45.0,45,45,45,45.0,false,'45','45')
sql insert into tb4_0 values ('2021-10-20 10:04:55',55,55.0,55,55,55,55.0,false,'55','55')



D
dapan1121 已提交
137 138
run general/parser/interp_full_test1.sim
run general/parser/interp_full_test2.sim
D
dapan1121 已提交
139 140
run general/parser/interp_full_test3.sim
run general/parser/interp_full_test4.sim
D
dapan1121 已提交
141 142 143 144 145 146 147 148 149 150

#print ================== restart server to commit data into disk
#system sh/exec.sh -n dnode1 -s stop -x SIGINT
#sleep 500
#system sh/exec.sh -n dnode1 -s start
#print ================== server restart completed
#
#run general/parser/interp_full_test.sim
#
#system sh/exec.sh -n dnode1 -s stop -x SIGINT