32 1 Hierarchies and Relationships
Summary
- Namespaces organize multiple vocabularies so that they may be used at
the same time. - Namespaces are URIs that are declared in an XML document.
- Each namespace is either the default namespace or it has an abbreviation
called a prefix. - Element names and attributes may be qualified by using the namespace
prefix. - The default namespace applies to all unqualified elements. It does not
apply to unqualified attributes.
1.8 Exercises
- A spreadsheet was exported in comma-delimited format. The first few
lines look like this:
element_id,sequence_id,organism_name,seq_length,type
U83302,MICR83302,Colaptes rupicola,1047,DNA
U83303,HSU83303,Homo sapiens,3460,DNA
U83304,MMU83304,Mus musculus,51,RNA
U83305,MIASSU833,Accipiter striatus,1143,DNA
Show how these records would be written as XML elements using the
bio_sequencetag.
- For the spreadsheet in exercise 1.1 above, show the corresponding XML
DTD. Theelement_idattribute is a unique key for the element. As-
sume that all attributes are optional. The molecule type is restricted to the
biologically significant types of biopolymer. - Here is a relational database table that defines some physical units: