What should you do?

You are creating a SQL Server 2005 application that will store and manage legal documents. The original documents are stored as XML documents on a file server. The application will be used to insert the documents into the database. Later, the documents must be retrieved from the database. These documents must be identical to the originals.
You need to design a table to store the document data. What should you do?

You are creating a SQL Server 2005 application that will store and manage legal documents. The original documents are stored as XML documents on a file server. The application will be used to insert the documents into the database. Later, the documents must be retrieved from the database. These documents must be identical to the originals.
You need to design a table to store the document data. What should you do?

A.
Store the XML in a column that has a data type of nvarchar(max).

B.
Shred the XML and store it in a relational structure.

C.
Store the XML in a column that has a data type of XML.

D.
Store the XML in a column that has a data type of varchar(8000).

Explanation:
The possible Character Data Types are: char(n), nchar(N), varchar(n), varchar(max), nvarchar (max), text and ntext. Nvarchar(max) will store up to 2GB in maximum 536,870,912 characters and is used for Unicode data type that is variable length. The XML datatype is for well-formed documents and as you have to store the documents exactly as the original there is no guarantees that the documents are well formed.



Leave a Reply 0

Your email address will not be published. Required fields are marked *