vinayakb | 38b7ca4 | 2012-03-05 05:44:15 +0000 | [diff] [blame] | 1 | drop dataverse test if exists; |
| 2 | |
| 3 | create dataverse test; |
| 4 | use dataverse test; |
| 5 | |
| 6 | create type MyRecord as closed { |
| 7 | id: int32, |
| 8 | tweetid: int64, |
| 9 | loc: point, |
| 10 | time: datetime, |
| 11 | text: string |
| 12 | } |
| 13 | |
vinayakb | 38b7ca4 | 2012-03-05 05:44:15 +0000 | [diff] [blame] | 14 | create dataset MyData(MyRecord) |
khfaraaz82@gmail.com | 502731f | 2012-05-02 20:38:16 +0000 | [diff] [blame] | 15 | partitioned by key id; |
vinayakb | 38b7ca4 | 2012-03-05 05:44:15 +0000 | [diff] [blame] | 16 | |
| 17 | load dataset MyData |
| 18 | using "edu.uci.ics.asterix.external.dataset.adapter.NCFileSystemAdapter" |
| 19 | (("path"="nc1://data/twitter/smalltweets.txt"),("format"="adm")) pre-sorted; |
| 20 | |
vinayakb | 38b7ca4 | 2012-03-05 05:44:15 +0000 | [diff] [blame] | 21 | delete $l from dataset MyData where $l.id>=50 die after 1500; |
| 22 | |
| 23 | write output to nc1:"rttest/failure_delete-rtree.adm"; |
| 24 | |
| 25 | for $o in dataset('MyData') |
| 26 | order by $o.id |
| 27 | return {"id":$o.id} |