adding test scripts
[csql.git] / test / tools / csql / exp.test037.ksh
blobf649161a638a67bb8ebee5d932e729235dfdc432
1 echo tinyint data type testing;
2 Statement Executed
3 Statement Executed: Rows Affected = 1
4 Statement Executed: Rows Affected = 1
5 Statement Executed: Rows Affected = 1
6 Statement Executed: Rows Affected = 1
7 Statement Executed: Rows Affected = 1
8 Statement Executed: Rows Affected = 1
9 echo select * from t1;
10 ---------------------------------------------------------
11 t1.f1 t1.f2
12 ---------------------------------------------------------
13 10 1
14 11 1
15 12 1
16 13 1
17 -128 1
18 127 1
20 echo select * from t1 where f1 = 10;
21 ---------------------------------------------------------
22 t1.f1 t1.f2
23 ---------------------------------------------------------
24 10 1
26 echo select * from t1 where f1 != 12 AND f2 <= 13;
27 ---------------------------------------------------------
28 t1.f1 t1.f2
29 ---------------------------------------------------------
30 10 1
31 11 1
32 13 1
33 -128 1
34 127 1
36 echo select * from t1 where f1 = 12 AND f2 >= 22;
37 ---------------------------------------------------------
38 t1.f1 t1.f2
39 ---------------------------------------------------------
41 echo select * from t1 where f1 = 12 OR f1 > 13;
42 ---------------------------------------------------------
43 t1.f1 t1.f2
44 ---------------------------------------------------------
45 12 1
46 127 1
48 echo select * from t1 where f1 = 12 OR f2 < 13;
49 ---------------------------------------------------------
50 t1.f1 t1.f2
51 ---------------------------------------------------------
52 10 1
53 11 1
54 12 1
55 13 1
56 -128 1
57 127 1
59 echo select * from t1 where f1 = 12 OR f2 <> 22;
60 ---------------------------------------------------------
61 t1.f1 t1.f2
62 ---------------------------------------------------------
63 10 1
64 11 1
65 12 1
66 13 1
67 -128 1
68 127 1
70 echo select * from t1 where NOT f1 = 12;
71 ---------------------------------------------------------
72 t1.f1 t1.f2
73 ---------------------------------------------------------
74 10 1
75 11 1
76 13 1
77 -128 1
78 127 1
80 echo select * from t1 where f1 != 12;
81 ---------------------------------------------------------
82 t1.f1 t1.f2
83 ---------------------------------------------------------
84 10 1
85 11 1
86 13 1
87 -128 1
88 127 1
90 echo select * from t1 where NOT f1 != 12;
91 ---------------------------------------------------------
92 t1.f1 t1.f2
93 ---------------------------------------------------------
94 12 1
96 echo select * from t1 where f1 = f2;
97 ---------------------------------------------------------
98 t1.f1 t1.f2
99 ---------------------------------------------------------
101 echo select * from t1 where f1 between 126 and 127;
102 ---------------------------------------------------------
103 t1.f1 t1.f2
104 ---------------------------------------------------------
105 127 1
107 echo select * from t1 where f1 between -127 and -128;
108 ---------------------------------------------------------
109 t1.f1 t1.f2
110 ---------------------------------------------------------
112 echo update t1 set f2 = 2 where f1 != f2;
113 Statement Executed: Rows Affected = 6
114 ---------------------------------------------------------
115 t1.f1 t1.f2
116 ---------------------------------------------------------
117 10 2
118 11 2
119 12 2
120 13 2
121 -128 2
122 127 2
124 echo update t1 set f2 = 3 where f1 = 12;
125 Statement Executed: Rows Affected = 1
126 ---------------------------------------------------------
127 t1.f1 t1.f2
128 ---------------------------------------------------------
129 10 2
130 11 2
131 12 3
132 13 2
133 -128 2
134 127 2
136 Statement Executed: Rows Affected = 1
137 ---------------------------------------------------------
138 t1.f1 t1.f2
139 ---------------------------------------------------------
140 10 2
141 11 2
142 13 2
143 -128 2
144 127 2
146 Statement Executed