• +91 9723535972
  • info@interviewmaterial.com

XML Interview Questions and Answers

XML Interview Questions and Answers

Question - 11 : - What is SOAP and how does it relate to XML?

Answer - 11 : - The Simple Object Access Protocol (SOAP) uses XML to define a protocol for the exchange of information in distributed computing environments. SOAP consists of three components: an envelope, a set of encoding rules, and a convention for representing remote procedure calls. Unless experience with SOAP is a direct requirement for the open position, knowing the specifics of the protocol, or how it can be used in conjunction with HTTP, is not as important as identifying it as a natural application of XML

Question - 12 : - Why not just carry on extending HTML?

Answer - 12 : - HTML was already overburdened with dozens of interesting but incompatible inventions from different manufacturers, because it provides only one way of describing your information. XML allows groups of people or organizations to question C.13, create their own customized markup applications for exchanging information in their domain (music, chemistry, electronics, hill-walking, finance, surfing, petroleum geology, linguistics, cooking, knitting, stellar cartography, history, engineering, rabbit-keeping, question C.19, mathematics, genealogy, etc). HTML is now well beyond the limit of its usefulness as a way of describing information, and while it will continue to play an important role for the content it currently represents, many new applications require a more robust and flexible infrastructure.

Question - 13 : - Give some examples of XML DTDs or schemas that you have worked with.

Answer - 13 : - Although XML does not require data to be validated against a DTD, many of the benefits of using the technology are derived from being able to validate XML documents against business or technical architecture rules. Polling for the list of DTDs that developers have worked with provides insight to their general exposure to the technology. The ideal candidate will have knowledge of several of the commonly used DTDs such as FpML, DocBook, HRML, and RDF, as well as experience designing a custom DTD for a particular project where no standard existed.

Question - 14 : - Using XSLT, how would you extract a specific attribute from an element in an XML document?

Answer - 14 : -  xsl:template to match the appropriate XML element, xsl:value-of to select the attribute value, and the optional xsl:apply-templates to continue processing the document. Extract Attributes from XML Data Attribute Value:

Question - 15 : - When constructing an XML DTD, how do you create an external entity reference in an attribute value?

Answer - 15 : - Every interview session should have at least one trick question. Although possible when using SGML, XML DTDs don't support defining external entity references in attribute values. It's more important for the candidate to respond to this question in a logical way than than the candidate know the somewhat obscure answer.

Question - 16 : - How would you build a search engine for large volumes of XML data?

Answer - 16 : - answer is to build a full-text search and handle the data similarly to the way Internet portals handle HTML pages. Others consider XML as a standard way of transferring structured data between disparate systems. These candidates often describe some scheme of importing XML into a relational or object database and relying on the database's engine for searching. Lastly, candidates that have worked with vendors specializing in this area often say that the best way the handle this situation is to use a third party software package optimized for XML data.

Question - 17 : - What is the difference between XML and C or C++ or Java ?

Answer - 17 : - C and C++ (and other languages like FORTRAN, or Pascal, or Visual Basic, or Java or hundreds more) are programming languages with which you specify calculations, actions, and decisions to be carried out in order: mod curconfig[if left(date,6) = "01-Apr", t.put "April googlel!", f.put days('31102005','DDMMYYYY') - days(sdate,'DDMMYYYY') " more shopping days to Samhain"]; XML is a markup specification language with which you can design ways of describing information (text or data), usually for storage, transmission, or processing by a program. It says nothing about what you should do with the data (although your choice of element names may hint at what they are for): Camshaft end bearing retention circlip Ringtown Fasteners Ltd Angle-nosed insertion tool is required for the removal and replacement of this part. On its own, an SGML or XML file (including HTML) doesn't do anything. It's a data format which just sits there until you run a program which does something with it.

Question - 18 : - Does XML replace HTML?

Answer - 18 : - No. XML itself does not replace HTML. Instead, it provides an alternative which allows you to define your own set of markup elements. HTML is expected to remain in common use for some time to come, and the current version of HTML is in XML syntax. XML is designed to make the writing of DTDs much simpler than with full SGML. (See the question on DTDs for what one is and why you might want one.)

Question - 19 : - Do I have to know HTML or SGML before I learn XML?

Answer - 19 : - No, although it's useful because a lot of XML terminology and practice derives from two decades' experience of SGML. Be aware that ‘knowing HTML’ is not the same as ‘understanding SGML’. Although HTML was written as an SGML application, browsers ignore most of it (which is why so many useful things don't work), so just because something is done a certain way in HTML browsers does not mean it's correct, least of all in XML.

Question - 20 : - What does an XML document actually look like (inside)?

Answer - 20 : - The basic structure of XML is similar to other applications of SGML, including HTML. The basic components can be seen in the following examples. An XML document starts with a Prolog: 1. The XML Declaration which specifies that this is an XML document; 2. Optionally a Document Type Declaration which identifies the type of document and says where the Document Type Description (DTD) is stored; The Prolog is followed by the document instance: 1. A root element, which is the outermost (top level) element (start-tag plus end-tag) which encloses everything else: in the examples below the root elements are conversation and titlepage; 2. A structured mix of descriptive or prescriptive elements enclosing the character data content (text), and optionally any attributes (‘name=value’ pairs) inside some start-tags. XML documents can be very simple, with straightforward nested markup of your own design:
Hello, world! Stop the planet, I want to get off!
Or they can be more complicated, with a Schema or question C.11, Document Type Description (DTD) or internal subset (local DTD changes in [square brackets]), and an arbitrarily complex nested structure: ]> Hello, world!


NCERT Solutions

 

Share your email for latest updates

Name:
Email:

Our partners