Win a copy of Beginning Java 17 Fundamentals: Object-Oriented Programming in Java 17 this week in the Java in General forum!

Scott Collens

Greenhorn
+ Follow
since Jun 21, 2001
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Scott Collens

Yes, you can call a template from within another 'called' template similar to functions or stored procedure calls in conventional programming. This is how you use recursion to process a node-set.
Thanks Map.
No problem Vladan. Let me know if I can be of anymore assistance.
I passed the test today and I thought I'd pass along my experience which more or less confirms what others have offered.
The test itself is indeed heavy on DTD, XSL and XML Design.
There was a business case where they ask you architecture and design questions. They also ask you questions on how to achieve a desired result from the application provided. (Ajith's sample test on Design is a good test of your understanding of these concepts).
I only had one question where XML & XSL were supplied and the output was asked for. (easy)
One question on xsl-fo, XLink, and schema. IMO: Don't bother with the specifics of these, just know the general specs.
Know XPath! 4-5 questions. For this, use the tutorial at www.zvon.org and the w3 specs (the XPath specs are straightforward and not so long). For good examples of XPath -- use Wrox's XSLT - Programmer's Reference by Michael Kay, Chapter 5.
I also strongly recommend going through Michael Kay's book for XSLT. It is an excellent source. There are many good examples on www.zvon.org, but I didn't find them as useful as the book for the high-level type of questions that were asked.
There were approx 5 questions where the DTD or some specs were given and you had to choose which answer conformed. (For DTD I used Wrox's Professional XML).
5-6 question on DOM & Sax: Again Wrox's Professional XML helped.
Overall: I would say that syntax was only an issue in 4-5 questions. Most questions were high-level, designed to test your understanding of the concepts. Alot of common sense and a decent grasp of specs should get you by.
As mentioned before. Time is an issue. Manage it wisely.
Hope this helps.

[This message has been edited by Scott Collens (edited July 26, 2001).]
In order to validate your document and render it in a browser it is not necessary to have all three. In your xml document, you can have an internal DTD immediately following your xml declaration (you can have comments and processing instructions in between them). Then you would only have the xml document containing your your DTD and a xsl file for rendering.
I am not sure if you can include schemas internally in an xml file, but you can with DTD.
[This message has been edited by Scott Collens (edited July 25, 2001).]
Once again, I apologize if this has been discussed before.
Here is question 3 from the Exam List's DTD Exam:
3. Which of the following code is valid?
a)<!DOCTYPE test [ <!ELEMENT test (#PCDATA)>]>
b)<!DOCTYPE test [ <!ELEMENT test.dtd (elm1|elm2|#PCDATA) >]>
c)<!DOCTYPE test [ <!ELEMENT test.dtd (#PCDATA|elm1|elm2)* >]>
d)<!DOCTYPE test [ <!ELEMENT test test (#PCDATA)>]>
e)<!DOCTYPE test [ <!ELEMENT test "test" (#PCDATA)>]>
Answer : a c
It says that answer a & c are both correct. I believe only answer 'a' to be correct, because 'c' states that the root element is 'test' and then goes on to declare that root element as 'test.dtd', making the code invalid.

I guess it is possible that the element declaration is not the root and assumes that there would be other element declarations to come before it (one of which would be a root element called 'test.dtd'). That doesn't seem likely, nor does it make this code (as it is) anymore valid.
Can someone give me some feedback on this?
Thanks in advance.
You are correct.
The result of the evaluation expression is always converted to a string. Therefore it looks at the first digit in the number for its first filter, then the second and so on. To order the numbers properly you must set the data-type attribute to number.
<xsl:sort select="expression" data-type="number" order="ascending"/>
XSL gives a broader scope of transforming XML. XSLT is just one part of the process.
w3schools.com gives a pretty decent tutorial outlining the difference.
http://www.w3schools.com/xsl/xsl_intro.asp
16. Which one of the following XML content models is NOT allowed?
<!element Customer (Name, Ship-to-address?, Bill-to-address?)>
<!element Customer ((Name, Ship-to-address) | (Name, Bill-to-address))>
<!element Customer (Name, (Ship-to-address | Bill-to-address)?)>
<!element Customer (Name, (Ship-to-address, Bill-to-address)?)>
The test says the answer is b.
b should be allowed along with all other selections.
Can anyone confirm this? I apologize if this has been discussed previously.
Hi guys,
I am taking the IBM XML Certification test in 1 week. I was wondering if anyone had done any of the practice tests from XML@Whiz. Is the test engine worth spending the money ($30 US)?
Thanks in advance.....Scott

Originally posted by Vlad Patryshev:
Regarding input: what kind of magic in your opinion makes it possible for DOM just to skip pieces the input file up to the right position where relevant data can be found, as opposed to SAX which reads the same characters and passes them to handlers which in turn are free to skip thiem?
Regarding output: does SAX has anything to do with document output?


My apologies. I was considering that one may want to update the info., rather than just extract it. I tend to agree with Brooklyn. SAX appears to be the the correct solution.
Regarding output. Once again, I apologize for my poor choice of words. If some one has contacted the author of the test, can you kindly post the response.
For question 1:
I believe 'a' is not correct because, although it is true that SAX offers better performance than DOM with large documents, 'b' is MORE likely to be used because SAX forces you to read the document sequentially whereas DOM allows you to navigate to a portion of the document and manipulate the data in place. This satisfies the requirement of extracting very few of the information from the document in a timely manner. If you were outputting the entire document, SAX would be more efficient, and thus 'a' would be correct.
Question 2:
Again both are correct, but we need to answer which is MORE likely. Although it is true that the efficiency of processing large documents is greater with SAX than DOM, the fact that the document MUST be processed sequentially suggest that the only logical choice can be SAX.
I have solved half the problem. When using mixed content the elements must be declared as zero or more cardinality, so the parent element can optionally include text or the child elements.
Is it illegal to combine multiple child elements as optional?
So if,
<!ELEMENT A (B,C)*>
You are saying A can include B and C one or more times, but if it does not include one it cannot inlude the other. Isit legal to do this?
Scott
I have a question regarding 2 questions on the DTD test located in Java Ranch's XML Exam List.
Question 1 reads as follows:

1. Which of the following dtd code is valid?
a)<!ELEMENT test (#CDATA)>
b)<!ELEMENT test (#PCDATA)>
c)<!ELEMENT test (#ANY)>
d)<!ELEMENT test (this,that)*>
right
Answer : b


Can someone tell me why 'd' is not valid?
In the 3rd question it seems that answer 'c' is similar to answer 'd' in the first question but the answer says it is valid. Why is this code valid while answer 'd' in question 1 is not.

. Which of the following code is valid?

a)<!DOCTYPE test [ <!ELEMENT test (#PCDATA)>]>
b)<!DOCTYPE test [ <!ELEMENT test.dtd (elm1|elm2|#PCDATA) >]>
c)<!DOCTYPE test [ <!ELEMENT test.dtd (#PCDATA|elm1|elm2)* >]>
d)<!DOCTYPE test [ <!ELEMENT test test (#PCDATA)>]>
e)<!DOCTYPE test [ <!ELEMENT test "test" (#PCDATA)>]>


Thanks....Scott
[This message has been edited by Scott Collens (edited June 27, 2001).]