[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Another lookup problem (well-formed vs. valid)

Subject: Re: Another lookup problem (well-formed vs. valid)
From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx>
Date: Tue, 13 May 2003 16:56:12 -0400
xerces well formed
Hi Chris,

At 03:48 PM 5/13/2003, you wrote:
I'm thinking I could use document('....') to pull in the other data,
and I could use <xsl:key> to access the data, but I'm concerned
that the other data doesn't conform to the same DTD as the rest.

It shouldn't be a problem. Whether the data is any good is a separable question from whether it conforms to a particular (or any) DTD. :->


I hope (not yet proven) that the other data source is at least well-
formed -- my validating parser hasn't shown me any well-formedness
errors. (By the way, this is off-topic, but does anybody happen to
know how I can just call a non-validating parser to confirm that a
document is well-formed? I have access to xalan/xerces and expat
(nee nsgmls) -- probably some others but not immediately to hand)
Will I be able to just call in the other document without worrying about
its validity?

If it's truly well-formed, yes. (Again, you still might have to worry about the quality of the data.)


All XML parsers do wf-checking; most validating parsers have a switch to allow you to turn validation off. For tasks such as you're looking at, I like the RXP parser (google XML RXP parser), which is fast and conformant and runs from a command line, with various switches including this one. I know for sure that Xerces has such a switch: in its docs you want to look at "SAXCount" or some other mini-application.

One more complication: the additional source document is in 27 pieces,
so I was combining them using the internal subset on the DOCTYPE
line, like so:

<!DOCTYPE OPR PUBLIC "-//xxx/DTD xxx//" "Oro-v315.dtd" [
<!ENTITY efa SYSTEM "./ef/xmlout/efa.xml">
...]
>
&efa;
...

An old SGML trick which is still very handy, but here I'm concerned
that I'm no longer in pure well-formedness once I've put that DOCTYPE
line in there.

You're still well-formed: not to worry. (You're not "standalone" though.) This won't be an issue until you run into some tool that doesn't conform to the Rec in this respect.


Cheers,
Wendell


====================================================================== Wendell Piez mailto:wapiez@xxxxxxxxxxxxxxxx Mulberry Technologies, Inc. http://www.mulberrytech.com 17 West Jefferson Street Direct Phone: 301/315-9635 Suite 207 Phone: 301/315-9631 Rockville, MD 20850 Fax: 301/315-8285 ---------------------------------------------------------------------- Mulberry Technologies: A Consultancy Specializing in SGML and XML ======================================================================


XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list



Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.