Chapter 26 Outline - Structured Data:
- e.g., information stored in databases; all records have the same format as defined in the relational schema
- Semistructured data may have a certain structure but no all the information collected will have identical structure.
FIGURE 26.1 Representing semistructured data as a graph. FIGURE 26.2 Part of an HTML document representing unstructured data (c.f., the company database schema) XML Hierarchical (Tree) Data Model - Problem with HTML document:
- Difficult to interpret automatically by programs because they do not include schema information about the type of data in the documents
- Inappropriate as intermediate Web documents to be exchanged among various computer sites
- Solution XML documents
- Two main structuring concepts: elements, attributes
- c.f., In XML, tag names are defined to describe the meaning of the data elements, rather than to describe how the text is to be displayed (as in HTML).
FIGURE 26.3 A complex XML element called
. - Complex elements:
,
, - Simple elements: , , , …
- Standalone=“yes”
- - schemaless
XML Documents, DTD, and XML Schema - A well-formed XML document is one that follows a few conditions.
- Start with an XML declaration (version, …)
- Tree model
- A single root element
- Matching start and end tags for an element must be within the tags of the parent element
- Syntactically correct
Do'stlaringiz bilan baham: |