test005.ksh

来自「b树实现源码,linux和unix下运行,速度快,极好用」· KSH 代码 · 共 53 行

KSH
53
字号
#!/bin/sh# TestCase:# check pages used(normal and merged) and chunks used for user database# create table t1 with two fields # check pages used(normal and merged) and chunks used for user database# drop table t1# check pages used(normal and merged) and chunks used for user database#Run this test only under csql/test or on this directory.#Otherwise, it may failEXECUTABLE=${PWD}/system/Allocator/createREL_PATH=.if [ -s "$EXECUTABLE" ]then    REL_PATH=${PWD}/system/Allocatorfiecho "Case 1: -d option with no table"$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -d if [ $? -ne 0 ]then   exit 1;fi${REL_PATH}/createNoIndexif [ $? -ne 0 ]then   exit 100;fiecho "Tables and Indexes are created"echo "Case 2: -d option with 1 table"$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -d if [ $? -ne 0 ]then   exit 1;fi${REL_PATH}/dropif [ $? -ne 0 ]then   exit 100;fiecho "Case 3: -d option after removing table"$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -dif [ $? -ne 0 ]then   exit 3;fiexit 0

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?