Changeset: 7ff400893d69 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=7ff400893d69
Added Files:
        sql/test/VOC/VOCcreate_user.sql
        sql/test/VOC/VOCdrop.sql
        sql/test/VOC/VOCdrop_user.sql
        sql/test/VOC/VOCinsert.sql
        sql/test/VOC/VOCmanual_examples.sql
        sql/test/VOC/VOCquery.sql
Modified Files:
        sql/backends/monet5/sql_gencode.c
        sql/benchmarks/nobench/Tests/nobench.sql
        sql/benchmarks/nobench/Tests/nobench.stable.out
        sql/test/VOC/Tests/VOC.SQL.py
        sql/test/VOC/Tests/VOC.stable.out
        sql/test/VOC/Tests/double_is_null.Bug-3116.sql
        sql/test/VOC/Tests/double_is_null.Bug-3116.stable.out
        sql/test/VOC/Tests/median.Bug-3096.sql
        sql/test/VOC/Tests/median.Bug-3096.stable.out
        sql/test/VOC/VOCschema.sql
Branch: default
Log Message:

Merge with linear-hashing branch.


diffs (truncated from 58711 to 300 lines):

diff --git a/sql/backends/monet5/sql_gencode.c 
b/sql/backends/monet5/sql_gencode.c
--- a/sql/backends/monet5/sql_gencode.c
+++ b/sql/backends/monet5/sql_gencode.c
@@ -434,9 +434,13 @@ static int
                        const char *nme = 
(op->op3)?op->op3->op4.aval->data.val.sval:op->cname;
 
                        if ((nr + 100) > len) {
-                               buf = GDKrealloc(buf, len*=2);
-                               if(buf == NULL)
+                               char *tmp = GDKrealloc(buf, len*=2);
+                               if (tmp == NULL) {
+                                       GDKfree(buf);
+                                       buf = NULL;
                                        break;
+                               }
+                               buf = tmp;
                        }
 
                        nr += snprintf(buf+nr, len-nr, "%s %s(%u,%u)%c", nme, 
t->type->sqlname, t->digits, t->scale, n->next?',':' ');
diff --git a/sql/benchmarks/nobench/Tests/nobench.sql 
b/sql/benchmarks/nobench/Tests/nobench.sql
--- a/sql/benchmarks/nobench/Tests/nobench.sql
+++ b/sql/benchmarks/nobench/Tests/nobench.sql
@@ -118,7 +118,7 @@ group by f.h;
 --                   ON (left.nested_obj.str = right.str1)
 --                   WHERE left.num BETWEEN XXXXX AND YYYYY;
 select * from bench10 as "left" inner join bench10 as "right" on 
(json.filter("left".js,'nested_obj.str') = json.filter("right".js, 'str1'))
- where json.number(json.filter("left".js,'num')) between 0.0 and 3.0;
+ where json.number(json.filter("left".js,'num')) between 0.0 and 3.0 order by 
"left".js;
 
 -- Q12 (use "extra" data file provided by generator):
 --   MongoDB:
diff --git a/sql/benchmarks/nobench/Tests/nobench.stable.out 
b/sql/benchmarks/nobench/Tests/nobench.stable.out
--- a/sql/benchmarks/nobench/Tests/nobench.stable.out
+++ b/sql/benchmarks/nobench/Tests/nobench.stable.out
@@ -293,10 +293,10 @@ stdout of test 'nobench` in directory 's
 % js,  js # name
 % json,        json # type
 % 465, 515 # length
+[ "{\"nested_obj\": {\"num\": 5, \"str\": \"GBRDCMBR\"}, \"sparse_008\": 
\"GBRDA===\", \"sparse_009\": \"GBRDA===\", \"dyn2\": false, \"dyn1\": 
\"GBRDA===\", \"nested_arr\": [], \"sparse_007\": \"GBRDA===\", \"str2\": 
\"GBRDCMBR\", \"str1\": \"GBRDA===\", \"sparse_004\": \"GBRDA===\", 
\"sparse_003\": \"GBRDA===\", \"sparse_002\": \"GBRDA===\", \"sparse_001\": 
\"GBRDA===\", \"sparse_000\": \"GBRDA===\", \"num\": 0, \"bool\": false, 
\"sparse_006\": \"GBRDA===\", \"thousandth\": 0, \"sparse_005\": 
\"GBRDA===\"}",    "{\"nested_obj\": {\"num\": 0, \"str\": \"GBRDA===\"}, 
\"dyn2\": 5, \"dyn1\": 5, \"nested_arr\": [\"the\", \"state\", \"aware\", 
\"''\", \"the\"], \"str2\": \"GBRDA===\", \"str1\": \"GBRDCMBR\", 
\"sparse_058\": \"GBRDCMBR\", \"thousandth\": 5, \"num\": 5, \"bool\": true, 
\"sparse_059\": \"GBRDCMBR\", \"sparse_054\": \"GBRDCMBR\", \"sparse_055\": 
\"GBRDCMBR\", \"sparse_056\": \"GBRDCMBR\", \"sparse_057\": \"GBRDCMBR\", 
\"sparse_050\": \"GBRDCMBR\", \"sparse_051\": \"GBRDCMBR\",
  \"sparse_052\": \"GBRDCMBR\", \"sparse_053\": \"GBRDCMBR\"}"  ]
+[ "{\"nested_obj\": {\"num\": 7, \"str\": \"GBRDCMJR\"}, \"dyn2\": 2, 
\"dyn1\": 2, \"nested_arr\": [\"she\", \"beyond\"], \"str2\": \"GBRDCMJR\", 
\"str1\": \"GBRDCMA=\", \"thousandth\": 2, \"sparse_025\": \"GBRDCMA=\", 
\"sparse_024\": \"GBRDCMA=\", \"sparse_027\": \"GBRDCMA=\", \"num\": 2, 
\"bool\": false, \"sparse_020\": \"GBRDCMA=\", \"sparse_023\": \"GBRDCMA=\", 
\"sparse_022\": \"GBRDCMA=\", \"sparse_021\": \"GBRDCMA=\", \"sparse_029\": 
\"GBRDCMA=\", \"sparse_028\": \"GBRDCMA=\", \"sparse_026\": \"GBRDCMA=\"}",     
   "{\"nested_obj\": {\"num\": 2, \"str\": \"GBRDCMA=\"}, \"dyn2\": 
\"GBRDCMJR\", \"dyn1\": 7, \"nested_arr\": [\"its\", \"for\", \"if\", \"he\", 
\"questions\", \"to\", \"put\"], \"str2\": \"GBRDCMA=\", \"str1\": 
\"GBRDCMJR\", \"sparse_079\": \"GBRDCMJR\", \"thousandth\": 7, \"sparse_078\": 
\"GBRDCMJR\", \"num\": 7, \"bool\": true, \"sparse_072\": \"GBRDCMJR\", 
\"sparse_073\": \"GBRDCMJR\", \"sparse_070\": \"GBRDCMJR\", \"sparse_071\": 
\"GBRDCMJR\", \"sparse_076\": \"GBRDCMJR
 \", \"sparse_077\": \"GBRDCMJR\", \"sparse_074\": \"GBRDCMJR\", 
\"sparse_075\": \"GBRDCMJR\"}" ]
 [ "{\"nested_obj\": {\"num\": 8, \"str\": \"GBRDCMBQGA======\"}, 
\"sparse_035\": \"GBRDCMI=\", \"dyn2\": true, \"dyn1\": 3, \"nested_arr\": 
[\"check\", \"it\", \"the\"], \"str2\": \"GBRDCMBQGA======\", \"str1\": 
\"GBRDCMI=\", \"thousandth\": 3, \"sparse_036\": \"GBRDCMI=\", \"sparse_037\": 
\"GBRDCMI=\", \"sparse_034\": \"GBRDCMI=\", \"num\": 3, \"bool\": true, 
\"sparse_033\": \"GBRDCMI=\", \"sparse_030\": \"GBRDCMI=\", \"sparse_031\": 
\"GBRDCMI=\", \"sparse_032\": \"GBRDCMI=\", \"sparse_038\": \"GBRDCMI=\", 
\"sparse_039\": \"GBRDCMI=\"}",       "{\"nested_obj\": {\"num\": 3, \"str\": 
\"GBRDCMI=\"}, \"dyn2\": 8, \"dyn1\": 8, \"nested_arr\": [], \"str2\": 
\"GBRDCMI=\", \"str1\": \"GBRDCMBQGA======\", \"thousandth\": 8, 
\"sparse_087\": \"GBRDCMBQGA======\", \"sparse_086\": \"GBRDCMBQGA======\", 
\"sparse_085\": \"GBRDCMBQGA======\", \"num\": 8, \"bool\": false, 
\"sparse_082\": \"GBRDCMBQGA======\", \"sparse_081\": \"GBRDCMBQGA======\", 
\"sparse_080\": \"GBRDCMBQGA======\", \"sparse_083\": \"G
 BRDCMBQGA======\", \"sparse_084\": \"GBRDCMBQGA======\", \"sparse_089\": 
\"GBRDCMBQGA======\", \"sparse_088\": \"GBRDCMBQGA======\"}"  ]
 [ "{\"sparse_018\": \"GBRDC===\", \"nested_obj\": {\"num\": 6, \"str\": 
\"GBRDCMJQ\"}, \"dyn2\": \"GBRDC===\", \"dyn1\": 1, \"nested_arr\": 
[\"button-down\"], \"sparse_010\": \"GBRDC===\", \"str2\": \"GBRDCMJQ\", 
\"str1\": \"GBRDC===\", \"sparse_013\": \"GBRDC===\", \"sparse_014\": 
\"GBRDC===\", \"sparse_015\": \"GBRDC===\", \"sparse_016\": \"GBRDC===\", 
\"sparse_017\": \"GBRDC===\", \"num\": 1, \"bool\": true, \"sparse_011\": 
\"GBRDC===\", \"thousandth\": 1, \"sparse_019\": \"GBRDC===\", \"sparse_012\": 
\"GBRDC===\"}",  "{\"nested_obj\": {\"num\": 1, \"str\": \"GBRDC===\"}, 
\"dyn2\": false, \"dyn1\": 6, \"nested_arr\": [\"to\", \"interrupted\", 
\"some\", \"daily\", \"has\", \"averages\"], \"str2\": \"GBRDC===\", \"str1\": 
\"GBRDCMJQ\", \"thousandth\": 6, \"sparse_069\": \"GBRDCMJQ\", \"sparse_068\": 
\"GBRDCMJQ\", \"num\": 6, \"bool\": false, \"sparse_061\": \"GBRDCMJQ\", 
\"sparse_060\": \"GBRDCMJQ\", \"sparse_063\": \"GBRDCMJQ\", \"sparse_062\": 
\"GBRDCMJQ\", \"sparse_065\": \"GBRDC
 MJQ\", \"sparse_064\": \"GBRDCMJQ\", \"sparse_067\": \"GBRDCMJQ\", 
\"sparse_066\": \"GBRDCMJQ\"}"      ]
-[ "{\"nested_obj\": {\"num\": 7, \"str\": \"GBRDCMJR\"}, \"dyn2\": 2, 
\"dyn1\": 2, \"nested_arr\": [\"she\", \"beyond\"], \"str2\": \"GBRDCMJR\", 
\"str1\": \"GBRDCMA=\", \"thousandth\": 2, \"sparse_025\": \"GBRDCMA=\", 
\"sparse_024\": \"GBRDCMA=\", \"sparse_027\": \"GBRDCMA=\", \"num\": 2, 
\"bool\": false, \"sparse_020\": \"GBRDCMA=\", \"sparse_023\": \"GBRDCMA=\", 
\"sparse_022\": \"GBRDCMA=\", \"sparse_021\": \"GBRDCMA=\", \"sparse_029\": 
\"GBRDCMA=\", \"sparse_028\": \"GBRDCMA=\", \"sparse_026\": \"GBRDCMA=\"}",     
   "{\"nested_obj\": {\"num\": 2, \"str\": \"GBRDCMA=\"}, \"dyn2\": 
\"GBRDCMJR\", \"dyn1\": 7, \"nested_arr\": [\"its\", \"for\", \"if\", \"he\", 
\"questions\", \"to\", \"put\"], \"str2\": \"GBRDCMA=\", \"str1\": 
\"GBRDCMJR\", \"sparse_079\": \"GBRDCMJR\", \"thousandth\": 7, \"sparse_078\": 
\"GBRDCMJR\", \"num\": 7, \"bool\": true, \"sparse_072\": \"GBRDCMJR\", 
\"sparse_073\": \"GBRDCMJR\", \"sparse_070\": \"GBRDCMJR\", \"sparse_071\": 
\"GBRDCMJR\", \"sparse_076\": \"GBRDCMJR
 \", \"sparse_077\": \"GBRDCMJR\", \"sparse_074\": \"GBRDCMJR\", 
\"sparse_075\": \"GBRDCMJR\"}" ]
-[ "{\"nested_obj\": {\"num\": 5, \"str\": \"GBRDCMBR\"}, \"sparse_008\": 
\"GBRDA===\", \"sparse_009\": \"GBRDA===\", \"dyn2\": false, \"dyn1\": 
\"GBRDA===\", \"nested_arr\": [], \"sparse_007\": \"GBRDA===\", \"str2\": 
\"GBRDCMBR\", \"str1\": \"GBRDA===\", \"sparse_004\": \"GBRDA===\", 
\"sparse_003\": \"GBRDA===\", \"sparse_002\": \"GBRDA===\", \"sparse_001\": 
\"GBRDA===\", \"sparse_000\": \"GBRDA===\", \"num\": 0, \"bool\": false, 
\"sparse_006\": \"GBRDA===\", \"thousandth\": 0, \"sparse_005\": 
\"GBRDA===\"}",    "{\"nested_obj\": {\"num\": 0, \"str\": \"GBRDA===\"}, 
\"dyn2\": 5, \"dyn1\": 5, \"nested_arr\": [\"the\", \"state\", \"aware\", 
\"''\", \"the\"], \"str2\": \"GBRDA===\", \"str1\": \"GBRDCMBR\", 
\"sparse_058\": \"GBRDCMBR\", \"thousandth\": 5, \"num\": 5, \"bool\": true, 
\"sparse_059\": \"GBRDCMBR\", \"sparse_054\": \"GBRDCMBR\", \"sparse_055\": 
\"GBRDCMBR\", \"sparse_056\": \"GBRDCMBR\", \"sparse_057\": \"GBRDCMBR\", 
\"sparse_050\": \"GBRDCMBR\", \"sparse_051\": \"GBRDCMBR\",
  \"sparse_052\": \"GBRDCMBR\", \"sparse_053\": \"GBRDCMBR\"}"  ]
 #drop table bench10;
 
 # 13:08:14 >  
diff --git a/sql/test/VOC/Tests/VOC.SQL.py b/sql/test/VOC/Tests/VOC.SQL.py
--- a/sql/test/VOC/Tests/VOC.SQL.py
+++ b/sql/test/VOC/Tests/VOC.SQL.py
@@ -6,13 +6,19 @@ except ImportError:
 
 d = os.environ['RELSRCDIR']
 
-def client(file, user, passwd):
+def client(file, user, passwd, echo=None):
     sys.stdout.flush()
     sys.stderr.flush()
     c = process.client(lang = 'sql',
                        user = user, passwd = passwd,
                        args = [os.path.join(d, os.pardir, file)],
-                       log = True)
+                       log=True, echo=echo)
     c.communicate()
 
-client('VOCschema.sql', 'monetdb', 'monetdb')
+client('VOCcreate_user.sql', 'monetdb', 'monetdb')
+client('VOCschema.sql', 'voc', 'voc')
+client('VOCinsert.sql', 'voc', 'voc', echo=False)
+client('VOCquery.sql', 'voc', 'voc')
+client('VOCmanual_examples.sql', 'voc', 'voc')
+client('VOCdrop.sql', 'voc', 'voc')
+client('VOCdrop_user.sql', 'monetdb', 'monetdb')
diff --git a/sql/test/VOC/Tests/VOC.stable.out 
b/sql/test/VOC/Tests/VOC.stable.out
--- a/sql/test/VOC/Tests/VOC.stable.out
+++ b/sql/test/VOC/Tests/VOC.stable.out
@@ -154,133 +154,20 @@ stdout of test 'VOC` in directory 'sql/t
 #      "death_during_voyage"  integer,
 #      "onboard_at_arrival"   integer
 #);
-#COPY 8115 RECORDS INTO "voc"."voyages" FROM stdin USING DELIMITERS 
E'\t',E'\n','"';
-#1     ""      1       ""      "AMSTERDAM"     "Jan Jakobsz. Schellinger"      
260     NULL    "1594"  NULL    NULL    "A"     NULL    1595-04-02      "Texel" 
NULL    NULL    true    1596-06-06      "Engano"        NULL    "from 04-08 
till 11-08 in the Mosselbaai; from 13-09 till 07-10 in the Ampalazabaai; from 
09-10 till 13-12 in S. Augustins Bay, where before departure 127 of the 249 men 
were still alive; 11-01 till 21-01 at Ste. Marie I.; from 23-01 till 12-02 in 
the Bay of Antongil. The AMSTERDAM was set on fire near Bawean, 11-01-1597."
+#commit;
+
+# 17:10:01 >  
+# 17:10:01 >  Mtimeout -timeout 120 mclient -lsql -ftest -e --host=ottar 
--port=37097 --database=mTests_test_VOC 
../../../../../../../scratch1/sjoerd/src/MonetDB/candidate/sql/test/VOC/Tests/../VOCinsert.sql
+# 17:10:01 >  
+
 [ 8115 ]
-#COPY 2349 RECORDS INTO "voc"."craftsmen" FROM stdin USING DELIMITERS 
E'\t',E'\n','"';
-#1376  ""      3       ""      19      NULL    NULL    NULL    NULL    19
-#1378  ""      5       ""      22      NULL    NULL    NULL    NULL    22
-#1379  ""      5       ""      18      NULL    NULL    NULL    2       16
-#1380  ""      3       ""      11      NULL    NULL    NULL    1       10
-#1381  ""      5       ""      11      NULL    NULL    NULL    NULL    11
-#1383  ""      5       ""      7       NULL    NULL    NULL    NULL    7
-#1397  ""      3       ""      7       NULL    NULL    NULL    NULL    7
-#1401  ""      1       ""      4       NULL    NULL    NULL    1       3
-#1403  ""      3       ""      13      NULL    NULL    1       4       10
-#1482  ""      2       ""      3       NULL    3       NULL    NULL    NULL
-#1507  ""      2       ""      3       NULL    3       NULL    NULL    NULL
-#1516  ""      1       ""      NULL    NULL    NULL    2       NULL    2
 [ 2349 ]
-#COPY 938 RECORDS INTO "voc"."impotenten" FROM stdin USING DELIMITERS 
E'\t',E'\n','"';
-#5733  ""      3       ""      18      NULL    NULL    NULL    NULL    NULL
-#5734  ""      2       ""      19      NULL    NULL    NULL    NULL    NULL
-#5735  ""      1       ""      18      NULL    NULL    NULL    NULL    NULL
-#5736  ""      1       ""      20      NULL    NULL    NULL    NULL    NULL
-#5737  ""      4       ""      20      NULL    NULL    NULL    NULL    NULL
-#5751  ""      1       ""      9       NULL    NULL    NULL    NULL    NULL
-#5752  ""      5       ""      9       NULL    NULL    NULL    NULL    NULL
-#5755  ""      3       ""      16      NULL    NULL    NULL    NULL    NULL
-#5758  ""      5       ""      24      NULL    NULL    NULL    NULL    NULL
-#5759  ""      5       ""      17      NULL    NULL    NULL    NULL    NULL
-#5764  ""      2       ""      1       NULL    NULL    NULL    NULL    NULL
 [ 938  ]
-#COPY 3782 RECORDS INTO "voc"."invoices" FROM stdin USING DELIMITERS 
E'\t',E'\n','"';
-#5102  ""      2       ""      268964  "A"
-#5103  ""      2       ""      164562  "Z"
-#5105  ""      2       ""      110370  "A"
-#5106  ""      2       ""      127181  "D"
-#5107  ""      2       ""      101522  "A"
-#5108  ""      3       ""      110370  "A"
-#5110  ""      1       ""      21160   "A"
-#5112  ""      3       ""      192449  "R"
-#5113  ""      1       ""      231099  "A"
-#5114  ""      1       ""      32449   "Z"
-#5115  ""      1       ""      88907   "A"
-#5116  ""      2       ""      39787   "D"
-#5117  ""      1       ""      207498  "A"
-#5118  ""      1       ""      189448  "Z"
-#5119  ""      1       ""      136414  "H"
-#5120  ""      2       ""      56526   "H"
-#5121  ""      1       ""      48766   "E"
-#5122  ""      1       ""      235346  "A"
-#5123  ""      1       ""      140348  "E"
 [ 3782 ]
-#COPY 2813 RECORDS INTO "voc"."passengers" FROM stdin USING DELIMITERS 
E'\t',E'\n','"';
-#310   ""      2       ""      66      NULL    NULL    NULL    2       64
-#311   ""      2       ""      55      NULL    NULL    NULL    5       55
-#318   ""      5       ""      17      NULL    NULL    NULL    4       13
-#320   ""      3       ""      23      NULL    NULL    NULL    NULL    NULL
-#321   ""      2       ""      10      NULL    NULL    NULL    NULL    NULL
-#335   ""      1       ""      6       NULL    NULL    NULL    NULL    NULL
-#340   ""      1       ""      20      NULL    NULL    NULL    NULL    NULL
-#469   ""      1       ""      NULL    NULL    NULL    NULL    NULL    1
-#557   ""      1       ""      NULL    NULL    NULL    NULL    NULL    13
-#559   ""      1       ""      NULL    NULL    NULL    NULL    NULL    2
-#560   ""      5       ""      NULL    NULL    NULL    NULL    NULL    7
-#561   ""      2       ""      NULL    NULL    NULL    NULL    NULL    3
 [ 2813 ]
-#COPY 4468 RECORDS INTO "voc"."seafarers" FROM stdin USING DELIMITERS 
E'\t',E'\n','"';
-#196   ""      1       ""      65      NULL    NULL    NULL    NULL    NULL
-#197   ""      1       ""      22      NULL    NULL    NULL    NULL    NULL
-#296   ""      1       ""      126     NULL    NULL    NULL    NULL    NULL
-#298   ""      1       ""      147     NULL    NULL    NULL    NULL    NULL
-#299   ""      1       ""      89      NULL    NULL    NULL    NULL    NULL
-#301   ""      1       ""      152     NULL    NULL    NULL    NULL    NULL
-#302   ""      1       ""      105     NULL    NULL    NULL    NULL    NULL
-#303   ""      1       ""      54      NULL    NULL    NULL    NULL    NULL
-#304   ""      1       ""      20      NULL    NULL    NULL    NULL    NULL
-#305   ""      1       ""      109     NULL    NULL    NULL    NULL    NULL
-#306   ""      1       ""      50      NULL    NULL    NULL    NULL    NULL
 [ 4468 ]
-#COPY 4177 RECORDS INTO "voc"."soldiers" FROM stdin USING DELIMITERS 
E'\t',E'\n','"';
-#296   ""      1       ""      90      NULL    NULL    NULL    NULL    NULL
-#298   ""      1       ""      90      NULL    NULL    NULL    NULL    NULL
-#299   ""      1       ""      55      NULL    NULL    NULL    NULL    NULL
-#300   ""      1       ""      53      NULL    NULL    NULL    NULL    NULL
-#301   ""      1       ""      90      NULL    NULL    NULL    NULL    NULL
-#302   ""      1       ""      5       NULL    NULL    NULL    NULL    NULL
-#303   ""      1       ""      24      NULL    NULL    NULL    NULL    NULL
-#305   ""      1       ""      73      NULL    NULL    NULL    NULL    NULL
-#306   ""      1       ""      30      NULL    NULL    NULL    NULL    NULL
-#307   ""      1       ""      66      NULL    NULL    NULL    NULL    NULL
-#310   ""      2       ""      101     NULL    NULL    NULL    4       97
 [ 4177 ]
-#COPY 2454 RECORDS INTO "voc"."total" FROM stdin USING DELIMITERS 
E'\t',E'\n','"';
-#1     ""      1       ""      59      NULL    NULL    NULL    NULL    NULL
-#2     ""      1       ""      20      NULL    NULL    NULL    NULL    NULL
-#3     ""      1       ""      85      NULL    NULL    NULL    NULL    NULL
-#4     ""      1       ""      85      NULL    NULL    NULL    NULL    NULL
-#5     ""      1       ""      75      NULL    NULL    NULL    NULL    NULL
-#8     ""      1       ""      123     NULL    NULL    NULL    NULL    NULL
-#9     ""      1       ""      100     NULL    NULL    NULL    NULL    NULL
-#31    ""      2       ""      46      NULL    NULL    NULL    NULL    NULL
-#32    ""      3       ""      95      NULL    NULL    NULL    NULL    NULL
-#33    ""      3       ""      21      NULL    NULL    NULL    NULL    NULL
-#34    ""      3       ""      101     NULL    NULL    NULL    NULL    NULL
-#41    ""      1       ""      175     NULL    NULL    NULL    NULL    NULL
 [ 2454 ]
-#ALTER TABLE "voyages" ADD PRIMARY KEY ("number", "number_sup");
-#ALTER TABLE "craftsmen" ADD PRIMARY KEY ("number", "number_sup");
-#ALTER TABLE "impotenten" ADD PRIMARY KEY ("number", "number_sup");
-#ALTER TABLE "passengers" ADD PRIMARY KEY ("number", "number_sup");
-#ALTER TABLE "seafarers" ADD PRIMARY KEY ("number", "number_sup");
-#ALTER TABLE "soldiers" ADD PRIMARY KEY ("number", "number_sup");
-#ALTER TABLE "total" ADD PRIMARY KEY ("number", "number_sup");
-#ALTER TABLE "craftsmen" ADD FOREIGN KEY ("number", "number_sup")
-#      REFERENCES "voyages" ("number", "number_sup");
-#ALTER TABLE "impotenten" ADD FOREIGN KEY ("number", "number_sup")
-#      REFERENCES "voyages" ("number", "number_sup");
-#ALTER TABLE "invoices" ADD FOREIGN KEY ("number", "number_sup")
-#      REFERENCES "voyages" ("number", "number_sup");
-#ALTER TABLE "passengers" ADD FOREIGN KEY ("number", "number_sup")
-#      REFERENCES "voyages" ("number", "number_sup");
-#ALTER TABLE "seafarers" ADD FOREIGN KEY ("number", "number_sup")
-#      REFERENCES "voyages" ("number", "number_sup");
-#ALTER TABLE "soldiers" ADD FOREIGN KEY ("number", "number_sup")
-#      REFERENCES "voyages" ("number", "number_sup");
-#ALTER TABLE "total" ADD FOREIGN KEY ("number", "number_sup")
-#      REFERENCES "voyages" ("number", "number_sup");
-#commit;
 
 # 17:10:07 >  
 # 17:10:07 >  Mtimeout -timeout 120 mclient -lsql -ftest -e --host=ottar 
--port=37097 --database=mTests_test_VOC 
../../../../../../../scratch1/sjoerd/src/MonetDB/candidate/sql/test/VOC/Tests/../VOCquery.sql
diff --git a/sql/test/VOC/Tests/double_is_null.Bug-3116.sql 
b/sql/test/VOC/Tests/double_is_null.Bug-3116.sql
--- a/sql/test/VOC/Tests/double_is_null.Bug-3116.sql
+++ b/sql/test/VOC/Tests/double_is_null.Bug-3116.sql
@@ -1,5 +1,3 @@
-START TRANSACTION;
-
 CREATE TABLE "voyages" (
        "number"            integer     NOT NULL,
        "number_sup"        char(1)     NOT NULL,
@@ -28,4 +26,5 @@ CREATE TABLE "voyages" (
 SELECT hired, count(*)  FROM voyages WHERE   true  AND hired IS NOT NULL AND
 hired is not null GROUP BY hired ORDER BY hired;
 
-ROLLBACK;
+drop table voyages;
+
diff --git a/sql/test/VOC/Tests/median.Bug-3096.sql 
b/sql/test/VOC/Tests/median.Bug-3096.sql
--- a/sql/test/VOC/Tests/median.Bug-3096.sql
+++ b/sql/test/VOC/Tests/median.Bug-3096.sql
@@ -1,4 +1,3 @@
-START TRANSACTION;
 
 CREATE TABLE "voyages" (
        "number"            integer     NOT NULL,
@@ -28,4 +27,4 @@ CREATE TABLE "voyages" (
 select median(departure_date) - min(departure_date) from voyages;
 select max(departure_date) - min(departure_date) from voyages;
 
-ROLLBACK;
+drop table voyages;
diff --git a/sql/test/VOC/VOCcreate_user.sql b/sql/test/VOC/VOCcreate_user.sql
new file mode 100644
--- /dev/null
+++ b/sql/test/VOC/VOCcreate_user.sql
@@ -0,0 +1,7 @@
+START TRANSACTION;
+
+CREATE USER "voc" WITH PASSWORD 'voc' NAME 'VOC_EXPLORER' SCHEMA "sys";
+CREATE SCHEMA "voc" AUTHORIZATION "voc";
+ALTER USER "voc" SET SCHEMA "voc";
+
+commit;
diff --git a/sql/test/VOC/VOCdrop.sql b/sql/test/VOC/VOCdrop.sql
new file mode 100644
--- /dev/null
+++ b/sql/test/VOC/VOCdrop.sql
@@ -0,0 +1,12 @@
+START TRANSACTION;
+
+drop table total cascade;
+drop table soldiers cascade;
+drop table seafarers cascade;
+drop table passengers cascade;
+drop table invoices cascade;
+drop table impotenten cascade;
+drop table craftsmen cascade;
+drop table voyages cascade;
+
+commit;
diff --git a/sql/test/VOC/VOCdrop_user.sql b/sql/test/VOC/VOCdrop_user.sql
new file mode 100644
--- /dev/null
+++ b/sql/test/VOC/VOCdrop_user.sql
@@ -0,0 +1,7 @@
+START TRANSACTION;
+
+ALTER USER "voc" SET SCHEMA "sys";
+DROP SCHEMA "voc";
+DROP USER "voc";
+
+commit;
diff --git a/sql/test/VOC/VOCinsert.sql b/sql/test/VOC/VOCinsert.sql
new file mode 100644
--- /dev/null
+++ b/sql/test/VOC/VOCinsert.sql
@@ -0,0 +1,29132 @@
+START TRANSACTION;
+
+COPY 8115 RECORDS INTO "voc"."voyages" FROM stdin USING DELIMITERS 
E'\t',E'\n','"';
+1      ""      1       ""      "AMSTERDAM"     "Jan Jakobsz. Schellinger"      
260     NULL    "1594"  NULL    NULL    "A"     NULL    1595-04-02      "Texel" 
NULL    NULL    true    1596-06-06      "Engano"        NULL    "from 04-08 
till 11-08 in the Mosselbaai; from 13-09 till 07-10 in the Ampalazabaai; from 
09-10 till 13-12 in S. Augustins Bay, where before departure 127 of the 249 men 
were still alive; 11-01 till 21-01 at Ste. Marie I.; from 23-01 till 12-02 in 
the Bay of Antongil. The AMSTERDAM was set on fire near Bawean, 11-01-1597."
+2      ""      1       ""      "DUIFJE"        "Simon Lambrechtsz. Mau"        
50      "pinas" "1594"  NULL    NULL    "A"     NULL    1595-04-02      "Texel" 
NULL    NULL    true    1596-06-06      "Engano"        5001    "HOLLANDIA on 
26-10-1595; he was succeeded by Hendrik Jansz."
+3      ""      1       ""      "HOLLANDIA"     "Jan Dignumsz. van Kwadijk+"    
460     NULL    "1594"  NULL    NULL    "A"     NULL    1595-04-02      "Texel" 
NULL    NULL    true    1596-06-06      "Engano"        5002    "Jan Dignumsz. 
died on 29-05-1595 and Mau was his successor."
+4      ""      1       ""      "MAURITIUS"     "Jan Jansz. Molenaar"   460     
NULL    "1594"  NULL    NULL    "A"     NULL    1595-04-02      "Texel" NULL    
NULL    true    1596-06-06      "Engano"        5003    "Jan Jansz. died on 
25-12-1596 and Hendrik Jansz. was his successor."
+5      ""      1       ""      "LANGEBARK"     "Hans Huibrechtsz. Tonneman"    
300     NULL    NULL    NULL    NULL    NULL    NULL    1598-03-25      
"Zeeland"       NULL    NULL    true    1599-03-01      "Bantam"        5010    
"other."
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to