cat > script <<'+-+-+-+-+-END-OF-FILE-+-+-+-+-+'
select from t1;
alter t1 add c;
update t1 set c = b * 3;
select from t1;
create view v1 as select from t1 where b < c;
select from v1;
select b, b * b, c from t1;
create view v2 as select from t1 where ((b * b) < c);
select from v2;
create view v3 as select from t1 where ((b * b) <= c);
select from v3;
select a, strins (a, 2, 'c') from t1;
create view v4 as select from t1 where strins (a, 2, 'c') match '*cc*';
select from v4;
+-+-+-+-+-END-OF-FILE-+-+-+-+-+
chmod 644 script
cat > stdout <<'+-+-+-+-+-END-OF-FILE-+-+-+-+-+'
* select from t1;
a                b

abc              1
bcd              2
cde              3
def              4
efg              5
* alter t1 add c;
* update t1 set c = b * 3;
* select from t1;
a                b       c

abc              1       3
bcd              2       6
cde              3       9
def              4      12
efg              5      15
* create view v1 as select from t1 where b < c;
* select from v1;
a                b       c

abc              1       3
bcd              2       6
cde              3       9
def              4      12
efg              5      15
* select b, b * b, c from t1;
     b      (b * b)       c

     1            1       3
     2            4       6
     3            9       9
     4           16      12
     5           25      15
* create view v2 as select from t1 where ((b * b) < c);
* select from v2;
a                b       c

abc              1       3
bcd              2       6
* create view v3 as select from t1 where ((b * b) <= c);
* select from v3;
a                b       c

abc              1       3
bcd              2       6
cde              3       9
* select a, strins (a, 2, 'c') from t1;
a           STRINS(a, 2,  'c')

abc         acbc
bcd         bccd
cde         ccde
def         dcef
efg         ecfg
* create view v4 as select from t1 where strins (a, 2, 'c') match '*cc*';
* select from v4;
a                b       c

bcd              2       6
cde              3       9
* 
+-+-+-+-+-END-OF-FILE-+-+-+-+-+
chmod 644 stdout
cat > tag <<'+-+-+-+-+-END-OF-FILE-+-+-+-+-+'
Test expression on qualification capability on views.
+-+-+-+-+-END-OF-FILE-+-+-+-+-+
chmod 644 tag
