| /* |
| * Description : This test case is to verify the fix for issue205 |
| : https://code.google.com/p/asterixdb/issues/detail?id=205 |
| * Expected Res : Success |
| * Date : 26th November 2012 |
| */ |
| |
| drop dataverse test if exists; |
| create dataverse test; |
| use dataverse test; |
| |
| create type EmployeeStat as open { |
| age: int32, |
| salary:int32 |
| } |
| |
| create type EmployeeType as closed { |
| id:string, |
| stat:EmployeeStat, |
| deptCode:int32 |
| } |
| |
| create dataset Employees(EmployeeType) |
| primary key id; |
| |
| insert into dataset Employees({"id":"1234", "stat":{ "age":50, "salary":120000}, "deptCode":32 }); |
| insert into dataset Employees({"id":"5678", "stat":{ "age":40, "salary":100000}, "deptCode":16 }); |
| |
| delete $l from dataset Employees where $l.id = "1234"; |
| |
| write output to nc1:"rttest/dml_query-issue205.adm"; |
| for $l in dataset('Employees') |
| return $l |