math_pow2.sim 4.4 KB
Newer Older
S
shenglian zhou 已提交
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
sleep 100
sql connect
sql use db

print execute sql select pow(c2,stb1.c4),pow(c2,stba.c5) from stb1,stba where stb1.t1=stba.t1 and stb1.ts=stba.ts;
sql_error select pow(c2,stb1.c4),pow(c2,stba.c5) from stb1,stba where stb1.t1=stba.t1 and stb1.ts=stba.ts;
print execute sql select pow(c2,c4) as a from stb1 union all select pow(c2,c5) as a from stba;
sql select pow(c2,c4) as a from stb1 union all select pow(c2,c5) as a from stba;
if $data00 != @1.000000000@ then
  return -1 
endi
if $data10 != @NULL@ then
  return -1 
endi
if $data20 != @4.000000000@ then
  return -1 
endi
if $data30 != @NULL@ then
  return -1 
endi
if $data40 != @256.000000000@ then
  return -1 
endi
if $data50 != @inf@ then
  return -1 
endi
if $data60 != @-0.000000000@ then
  return -1 
endi
if $data70 != @1.000000000@ then
  return -1 
endi
if $data80 != @4.000000000@ then
  return -1 
endi
if $data90 != @9.000000000@ then
  return -1 
endi
print execute sql select pow(c2,c2) from stba;
sql select pow(c2,c2) from stba;
if $data00 != @1.000000000@ then
  return -1 
endi
if $data10 != @4.000000000@ then
  return -1 
endi
if $data20 != @27.000000000@ then
  return -1 
endi
if $data30 != @256.000000000@ then
  return -1 
endi
if $data40 != @3125.000000000@ then
  return -1 
endi
if $data50 != @46656.000000000@ then
  return -1 
endi
if $data60 != @823543.000000000@ then
  return -1 
endi
if $data70 != @16777216.000000000@ then
  return -1 
endi
if $data80 != @387420489.000000000@ then
  return -1 
endi
if $data90 != @1.000000000@ then
  return -1 
endi
print execute sql select pow(c2,min(c2)) from tba1;
sql_error select pow(c2,min(c2)) from tba1;
print execute sql select pow(c2,max(c2)) from tba1;
sql_error select pow(c2,max(c2)) from tba1;
print execute sql select pow(c2,count(c2)) from tba1;
sql_error select pow(c2,count(c2)) from tba1;
print execute sql select pow(c2,sum(c2)) from tba1;
sql_error select pow(c2,sum(c2)) from tba1;
print execute sql select pow(c2,avg(c2)) from tba1;
sql_error select pow(c2,avg(c2)) from tba1;
print execute sql select pow(c2,percentile(c2, 10)) from tba1;
sql_error select pow(c2,percentile(c2, 10)) from tba1;
print execute sql select pow(c2,apercentile(c2, 10)) from tba1;
sql_error select pow(c2,apercentile(c2, 10)) from tba1;
print execute sql select pow(c2,stddev(c2)) from tba1;
sql_error select pow(c2,stddev(c2)) from tba1;
print execute sql select pow(c2,spread(c2)) from tba1;
sql_error select pow(c2,spread(c2)) from tba1;
print execute sql select pow(c2,twa(c2)) from tba1;
sql_error select pow(c2,twa(c2)) from tba1;
print execute sql select pow(c2,leastsquares(c2, 1, 1)) from tba1;
sql_error select pow(c2,leastsquares(c2, 1, 1)) from tba1;
print execute sql select pow(c2,interp(c2)) from tba1 every(1s)
sql_error select pow(c2,interp(c2)) from tba1 every(1s)
print execute sql select pow(c2,interp(c2)) from stba every(1s) group by tbname;
sql_error select pow(c2,interp(c2)) from stba every(1s) group by tbname;
print execute sql select pow(c2,elapsed(ts)) from tba1;
sql_error select pow(c2,elapsed(ts)) from tba1;
print execute sql select pow(c2,rate(c2)) from tba1;
sql_error select pow(c2,rate(c2)) from tba1;
print execute sql select pow(c2,irate(c2)) from tba1;
sql_error select pow(c2,irate(c2)) from tba1;
print execute sql select pow(c2,first(c2)) from tba1;
sql_error select pow(c2,first(c2)) from tba1;
print execute sql select pow(c2,last(c2)) from tba1;
sql_error select pow(c2,last(c2)) from tba1;
print execute sql select pow(c2,last_row(c2)) from tba1;
sql_error select pow(c2,last_row(c2)) from tba1;
print execute sql select pow(c2,top(c2, 1)) from tba1;
sql_error select pow(c2,top(c2, 1)) from tba1;
print execute sql select pow(c2,bottom(c2, 1)) from tba1;
sql_error select pow(c2,bottom(c2, 1)) from tba1;
print execute sql select pow(c2,leastsquares(c2, 1, 1)) from tba1;
sql_error select pow(c2,leastsquares(c2, 1, 1)) from tba1;
print execute sql select pow(c2,derivative(c2, 1s, 0)) from tba1;
sql_error select pow(c2,derivative(c2, 1s, 0)) from tba1;
print execute sql select pow(c2,diff(c2)) from tba1;
sql_error select pow(c2,diff(c2)) from tba1;
print execute sql select pow(c2,csum(c2)) from tba1;
sql_error select pow(c2,csum(c2)) from tba1;
print execute sql select pow(c2,mavg(c2,2)) from tba1;
sql_error select pow(c2,mavg(c2,2)) from tba1;
print execute sql select pow(c2,sample(c2,2)) from tba1;
sql_error select pow(c2,sample(c2,2)) from tba1;
print execute sql select pow(c2,_block_dist()) from tba1;
sql_error select pow(c2,_block_dist()) from tba1;