blob: 0c805404e126f4ca203b332ad3eb34e5ca527ea2 [file] [log] [blame]
/*
* Description : Test cross dataverse functionality
* : use dataverse statement is now optional.
* : Use fully qualified names to create datasets, types.
* : drop datasets using fully qualified names
* : Query metadata to verify datasets are dropped.
* Expected Res : Success
* Date : 28th Aug 2012
*/
drop dataverse student if exists;
drop dataverse teacher if exists;
create dataverse student;
create dataverse teacher;
write output to nc1:"rttest/cross-dataverse_cross-dv03.adm";
create type student.stdType as open {
id : int32,
name : string,
age : int32,
sex : string,
dept : string
}
create type teacher.tchrType as open {
id : int32,
name : string,
age : int32,
sex : string,
dept : string
}
create dataset student.ugdstd(stdType) partitioned by key id;
create dataset student.gdstd(stdType) partitioned by key id;
create dataset teacher.prof(tchrType) partitioned by key id;
create dataset teacher.pstdoc(tchrType) partitioned by key id;
drop dataset student.ugdstd;
drop dataset student.gdstd;
drop dataset teacher.prof;
drop dataset teacher.pstdoc;
count(
for $l in dataset('Metadata.Dataset')
where $l.DataverseName='student' or $l.DataverseName='teacher'
return $l
)