runall
来自「postgresql8.3.4源码,开源数据库」· 代码 · 共 50 行
TXT
50 行
#! /bin/shPATH=..:$PATHecho "Testing PostgreSQL compilation..."LC_CTYPE=gr_GR.ISO8859-7LC_COLLATE=$LC_CTYPEexport LC_CTYPE LC_COLLATEecho "Testing LC_CTYPE..."if ! test-ctype > gr-ctype.out; then exit 1fidiff expected/gr-ctype.out gr-ctype.outecho "Testing LC_COLLATE..."perl ../sort-test.pl test-gr-sort.in > test-gr-sort.outdiff expected/test-gr-sort.out test-gr-sort.out### If you have Python - uncomment the following two lines#python ../sort-test.py test-gr-sort.in > test-gr-sort.out#diff expected/test-gr-sort.out test-gr-sort.outabort() { [ "$1" ] && echo "$*" exit 1}for f in char varchar text; do if echo $f | grep -q char; then ftype="$f(60)" else ftype="$f" fi echo "Testing PgSQL: sort on $ftype type..." dropdb testlocale >/dev/null 2>&1 createdb testlocale || abort "createdb failed" psql -d testlocale -c "CREATE TABLE usastates (abbrev char(2), name_en char(20), name_gr $ftype);" >/dev/null 2>&1 || abort "createtable failed" psql testlocale < test-gr.sql.in > test-gr-$f.sql.out 2>/dev/null || abort "test query failed" diff expected/test-gr-$f.sql.out test-gr-$f.sql.outdoneecho "Testing PgSQL: select on regexp..."psql testlocale < test-gr-select.sql.in > test-gr-select.sql.out 2>/dev/null || abort "select query failed"diff expected/test-gr-select.sql.out test-gr-select.sql.outdropdb testlocale || abort "dropdb failed"echo "Finished."
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?