Document Retrieval - Teradata Vantage

Teradata® VantageCloud Lake

Deployment
VantageCloud
Edition
Lake
Product
Teradata Vantage
Published
January 2023
ft:locale
en-US
ft:lastEdition
2024-12-11
dita:mapPath
phg1621910019905.ditamap
dita:ditavalPath
pny1626732985837.ditaval
dita:id
phg1621910019905

The following sections show how users can store XML documents into XML type columns and retrieve them using SQL queries that either retrieve the entire document or evaluate an XPath/XQuery expression that returns a single document node.

Consider the following queries:

SELECT id, xmldoc FROM xmltab;
SELECT id, xmldoc.xmlextract('.', NULL) FROM xmltab;

The result of each query represents a single tree rooted in a document node. The server returns the serialized representation of the document. The serialization of the document is not guaranteed to be lexically equivalent to the inserted document, but it is semantically equivalent (the canonical representation of the original document that was inserted and the document retrieved is lexically equivalent). Drivers can either parse the document returned or pass the stream to applications.