-- test for upgrade and downgrade
--
-- @@@ START COPYRIGHT @@@
--
-- Licensed to the Apache Software Foundation (ASF) under one
-- or more contributor license agreements.  See the NOTICE file
-- distributed with this work for additional information
-- regarding copyright ownership.  The ASF licenses this file
-- to you under the Apache License, Version 2.0 (the
-- "License"); you may not use this file except in compliance
-- with the License.  You may obtain a copy of the License at
--
--   http://www.apache.org/licenses/LICENSE-2.0
--
-- Unless required by applicable law or agreed to in writing,
-- software distributed under the License is distributed on an
-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-- KIND, either express or implied.  See the License for the
-- specific language governing permissions and limitations
-- under the License.
--
-- @@@ END COPYRIGHT @@@

set schema $$TEST_SCHEMA$$;
log LOG021 clear;
exit;

sh sqlci -i"TEST021(s0)" >> LOG021;

sh sqlci -i"TEST021(s1)" >> LOG021;

sh sqlci -i"TEST021(s11)" >> LOG021;

sh sqlci -i"TEST021(s2)" >> LOG021;

sh sqlci -i"TEST021(s3)" >> LOG021;

sh sqlci -i"TEST021(s4)" >> LOG021;

log;

exit;

?section s0
initialize trafodion, drop;

?section s1
initialize trafodion;

?section s11
create table t021 (a int not null);
create index t021i on t021(a);

select * from trafodion."_MD_".indexes;

showddl t021;
select * from t021;

?section s2
set parserflags 131072;
initialize trafodion, downgrade;

?section s3
initialize trafodion, upgrade;

?section s4
select * from trafodion."_MD_".indexes;

showddl t021;
select * from t021;


