What should you do to implement the plan while not modifying the application?

The database will contain a table. Customer data are stored in the table as XML data. The data supports an application that cannot be altered. You plan to prevent the types of errors below in the XML data:
* Invalid values in the Gender field,
* NULL values in the Customer Name field,
* Non-numeric values in the Customer Telephone field.
What should you do to implement the plan while not modifying the application?

The database will contain a table. Customer data are stored in the table as XML data. The data supports an application that cannot be altered. You plan to prevent the types of errors below in the XML data:
* Invalid values in the Gender field,
* NULL values in the Customer Name field,
* Non-numeric values in the Customer Telephone field.
What should you do to implement the plan while not modifying the application?

A.
You should use the FileStream data type.

B.
You should change the XML data type to Typed XML.

C.
You should validate data by using the HierarchyID data type.

D.
You should save the XML data in a standard table format.Specify the correct data types, constraints, and NOT NULL parameters in the standard table.

Explanation:
You can create variables, parameters, and columns of the xml type. You can optionally associate a collection of XML schemas with a variable, parameter, or column of xml type. In this case, the xml data type instance is called typed. Otherwise, the XML instance is called untyped.

Use untyped xml data type in the following situations:
– You do not have a schema for your XML data.
– You have schemas, but you do not want the server to validate the data. This is sometimes the case when an application performs client-side validation before storing the data at the server, or temporarily stores XML data that is invalid according to the schema, or uses schema components that are not supported at the server.

Use typed xml data type in the following situations:
– You have schemas for your XML data and you want the server to validate your XML data according to the XML schemas.
– You want to take advantage of storage and query optimizations based on type information.
– You want to take better advantage of type information during compilation of your queries.



Leave a Reply 0

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