khfaraaz82@gmail.com | a271613 | 2012-04-30 06:20:50 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Test case Name : open-closed-04.aql |
| 3 | * Description : This test is intended to test type in the Metdata for the dataset. |
| 4 | * : Verify if the type is open. |
| 5 | * Expected Result : Success - This should be allowed! |
| 6 | * Issue number : Issue 73 |
| 7 | */ |
| 8 | |
| 9 | drop dataverse test if exists; |
| 10 | |
| 11 | create dataverse test; |
| 12 | |
| 13 | use dataverse test; |
| 14 | |
| 15 | create type TestType as open { |
| 16 | id : int32, |
| 17 | name : string |
| 18 | } |
| 19 | |
| 20 | create dataset testds(TestType) partitioned by key id; |
| 21 | |
| 22 | /* |
| 23 | * Connect to the Metadata dataverse and run the following commands. |
| 24 | */ |
| 25 | |
| 26 | use dataverse Metadata; |
| 27 | |
| 28 | for $l in dataset('Datatype') |
| 29 | let $x := $l.Derived |
| 30 | where $l.DatatypeName="TestType" |
| 31 | return $x.Record |