Machine-translated by Google. Questions are authored in English.
Top

XML and ADO.NET Questions and Answers

Answer: B

Correct answer: elements and attributes.

A schema declares elements, which are the components of the document, and attributes, which qualify them, along with the types and the constraints on their occurrence. Properties and methods belong to the object model; tables and relationships to the relational one. The vocabulary follows the document view of the world.

Please log in or register to report this question.

32.

A well-formed XML document must have exactly one root element.

Answer: B

Correct answer: True

Every well-formed XML document has a single outermost element containing all others, which makes the document a single tree. Being well-formed is a weaker requirement than being valid, which additionally demands conformity to a schema or DTD.

Please log in or register to report this question.

33.

ADO.NET provides the ability to create and process in-memory databases called:

Answer: D

Correct answer: datasets.

A dataset is an in-memory relational structure: it holds tables, columns, rows and the relationships between them, and it is disconnected, so the application works on it without holding a connection open. It is the point at which ADO.NET bridges XML and relational data, since a dataset can be read from and written as XML.

Please log in or register to report this question.

Answer: D

Correct answer: XML is all of the above.

All three descriptions are correct and complementary. XML is a subset of SGML, simplified for practical use; it is a hybrid of document processing and database processing, being structured enough for one and flexible enough for the other; and it is a standardised way of describing content in which the vocabulary is chosen by the user.

Please log in or register to report this question.

35.

SOAP uses HTTP as its only transport mechanism.

Answer: B

Correct answer: False

SOAP is transport-independent by design. HTTP is much the commonest carrier, because it passes through firewalls that block other traffic, but a SOAP message can equally be sent over SMTP, over a message queue, or over anything else able to carry text. That independence is exactly what the generalisation from the original protocol achieved.

Please log in or register to report this question.

Answer: D

Correct answer: They have their own syntax.

An XML Schema is itself an XML document, so it uses XML syntax and nothing else - which is precisely what distinguishes it from a DTD, which does have a syntax of its own. The consequence is convenient: a schema can be parsed, validated and manipulated by ordinary XML tools.

Please log in or register to report this question.

37.

The most popular way to materialize XML documents is to use XSLT.

Answer: A

Correct answer: True

XSLT is the standard means of materialising XML: a stylesheet of match-and-action rules transforms the source into HTML for a browser, into another XML vocabulary for a different system, or into plain text. The transformation is declarative, and the same content can be materialised many ways by supplying different stylesheets.

Please log in or register to report this question.

38.

FOR XML EXPLICIT tells SQL Server to place the values of the columns as attributes in the resulting XML document.

Answer: B

Correct answer: False

That is what FOR XML RAW does. FOR XML EXPLICIT gives the developer complete control over the shape of the result, allowing some columns to become elements and others attributes and the hierarchy to be nested as required - at the cost of a considerably more complicated query.

Please log in or register to report this question.

39.

The DTD defines the structure of XML documents.

Answer: A

Correct answer: True

The DTD states which elements may appear, in what order and with what attributes, so it defines the structure of a class of documents. What it does not define is the appearance, which is XSLT’s business - the separation of structure from materialisation being one of the central ideas of XML.

Please log in or register to report this question.

40.

The most popular way to materialize XML documents is to use:

Answer: B

Correct answer: XSLT.

Materialisation is the production of a presentable document from XML content, and XSLT is the standard means: a stylesheet of match-and-action rules transforms the source document into HTML, into another XML vocabulary, or into text. A DTD defines structure rather than appearance, and SOAP is a messaging protocol.

Please log in or register to report this question.

Loading…
Tags: XML and ADO.NET Questions and Answers || XML and ADO.NET MCQ Questions and Answers || XML and ADO.NET GK Questions and Answers || XML and ADO.NET GK MCQ Questions || XML and ADO.NET Multiple Choice Questions and Answers || XML and ADO.NET GK || GK on XML and ADO.NET || Database Questions and Answers || Database MCQ Questions and Answers || Database GK Questions and Answers || GK on Database