blob: f883454b4626d2da0a21ea49ac5bb41e249fb711 [file] [log] [blame]
vinayakb38b7ca42012-03-05 05:44:15 +00001drop dataverse test if exists;
2
3create dataverse test;
4use dataverse test;
5
6create type MyRecord as closed {
7 id: int32,
8 tweetid: int64,
9 loc: point,
10 time: datetime,
11 text: string
12}
13
vinayakb38b7ca42012-03-05 05:44:15 +000014create dataset MyData(MyRecord)
ramangrover29669d8f62013-02-11 06:03:32 +000015 primary key id;
vinayakb38b7ca42012-03-05 05:44:15 +000016
17load dataset MyData
18using "edu.uci.ics.asterix.external.dataset.adapter.NCFileSystemAdapter"
19(("path"="nc1://data/twitter/smalltweets.txt"),("format"="adm")) pre-sorted;
20
vinayakb38b7ca42012-03-05 05:44:15 +000021delete $l from dataset MyData where $l.id>=50 die after 1500;
22
23write output to nc1:"rttest/failure_delete-rtree.adm";
24
25for $o in dataset('MyData')
26order by $o.id
27return {"id":$o.id}