vinayakb | 38b7ca4 | 2012-03-05 05:44:15 +0000 | [diff] [blame] | 1 | use dataverse demo1112; |
| 2 | |
| 3 | declare type CustomerType as open { |
| 4 | cid: int32, |
| 5 | name: string, |
| 6 | age: int32?, |
| 7 | address: AddressType?, |
| 8 | lastorder: { |
| 9 | oid: int32, |
| 10 | total: float |
| 11 | } |
| 12 | } |
| 13 | |
| 14 | declare type AddressType as open { |
| 15 | number: int32, |
| 16 | street: string, |
| 17 | city: string |
| 18 | } |
| 19 | |
| 20 | declare nodegroup group1 on nc1, nc2; |
| 21 | |
| 22 | declare dataset Customers(CustomerType) |
ramangrover29 | 669d8f6 | 2013-02-11 06:03:32 +0000 | [diff] [blame] | 23 | primary key cid on group1; |
vinayakb | 38b7ca4 | 2012-03-05 05:44:15 +0000 | [diff] [blame] | 24 | |
| 25 | load dataset Customers |
Ian Maxon | f18bba2 | 2015-08-21 12:35:14 -0700 | [diff] [blame] | 26 | using "org.apache.asterix.external.dataset.adapter.NCFileSystemAdapter" |
vinayakb | 38b7ca4 | 2012-03-05 05:44:15 +0000 | [diff] [blame] | 27 | (("path"="nc1:///tmp/customerData.adm"),("format"="json")) pre-sorted; |
| 28 | |