f



XML-tagging text document from W3C-schema

Is there an XML-editor that can assist you in marking up the data in an 
urformatted text document, such that you mark the data and then 
right-click to access the Schema you have assigned, and choose the 
tag/attribute in the tree-structure, which then magically appears with 
your data enclosed? There must be, right?

My assignment is to bring order to a truckload of stats from various 
Athletics events. For individual meetings, the formatting of the list of 
results are fairly standardized, but as a rule, they all follow their 
own standard, which means there's no hope making a script to automize 
the tagging, since there are several hundred meetings.

I have made a fairly simple schema which covers basicaly what I need in 
the way of tags, which is:

<statistics>
  <season name="" year="">
   <meeting name="" date="" country="" location="" arranger="" arena="">
    <event name="" category="">
     <participant lastname="" firstname="" born="" club="" result="" 
type="" place="" other=""/>
    </event>
   </meeting>
  </season>
</statistics>


Here's hoping for some suggestions!

-- 
A noise annoys an oyster
0
spam9080 (2)
4/4/2006 8:40:45 PM
comp.text.xml 8781 articles. 0 followers. Post Follow

1 Replies
561 Views

Similar Articles

[PageSpeed] 33

Jana wrote:
> Is there an XML-editor that can assist you in marking up the data in an 
> urformatted text document, such that you mark the data and then 
> right-click to access the Schema you have assigned, and choose the 
> tag/attribute in the tree-structure, which then magically appears with 
> your data enclosed? There must be, right?

Some, AFAIK. Although you don't pick the Schema/DTD after highlighting
the text, you pick it once at the start of the document. Then you 
highlight the whole text and enclose it in the root element, and then 
you break it into its component elements, tagging each one as you go.
And you probably wouldn't choose it from the tree structure but from
a menu.

I always use Emacs for this, as it has no problem in opening a non-XML
document and letting me add markup. But that's a personal choice, and
many people have serious concerns about seeing angle brackets in their
wild state.

> My assignment is to bring order to a truckload of stats from various 
> Athletics events. For individual meetings, the formatting of the list of 
> results are fairly standardized, but as a rule, they all follow their 
> own standard, which means there's no hope making a script to automize 
> the tagging, since there are several hundred meetings.

One alternative, if it is politically acceptable, is to ship them all
off to one of the many excellent companies in the Indian subcontinent
or the Pacific Rim, who are expert this kind of conversion.

Other wise writing a script *is* going to be easier than using an
editor, even with Emacs macros. Have a look at the plaintext handling
of XSLT2 or Omnimark for an "up-convert" (term for what you are trying
to do).

> I have made a fairly simple schema which covers basicaly what I need in 
> the way of tags, which is:

Before you start, make sure all the athletic associations which are
generating your data will use this schema in future. Otherwise you
or your successor will have the same problem all over again in a few
years. Regular readers of this group may remember the suboptimal
format selected by one international winter sporting organisation
which could easily have been done right if they had thought to ask
someone with a clue.

> <statistics>
>  <season name="" year="">
>   <meeting name="" date="" country="" location="" arranger="" arena="">
>    <event name="" category="">
>     <participant lastname="" firstname="" born="" club="" result="" 
> type="" place="" other=""/>
>    </event>
>   </meeting>
>  </season>
> </statistics>
> 
> 
> Here's hoping for some suggestions!

Make sure dates are always in the standard format: yyyy-mm-dd.
Anything else makes it impossible to sort the data.

Make as many as possible of the attributes token lists (in W3C
Schema terminology, "enumerated"). This will identify spelling
and formatting errors when you validate. It is essential that
the data is 100% regularised, otherwise any reports you generate
will have multiple differently-spelled groups.

Consider documenting the DTD or Schema and making it openly
available to the sporting community.

///Peter
-- 
XML FAQ: http://xml.silmaril.ie/
0
Peter
4/9/2006 9:03:17 PM
Reply:

Similar Artilces:

file command: "XML document text" vs "XML document text"
I've just used the file command on four files of RDF-XML with the following output: augtfidf.rdf: XML document text kyoto.rdf: XML document text stuff.rdf: XML document text tfidf.rdf: XML document text What does it mean that one of them has an extra space between "XML" and "document"? -- The kid's a hot prospect. He's got a good head for merchandising, an agent who can take you downtown and one of the best urine samples I've seen in a long time. [Dead Kennedys t-shirt] On 16.10.2012 16:06, Adam Funk wrote: > I've just used the file command on four files of RDF-XML with the > following output: > > augtfidf.rdf: XML document text > kyoto.rdf: XML document text > stuff.rdf: XML document text > tfidf.rdf: XML document text > > What does it mean that one of them has an extra space between "XML" > and "document"? Hard to tell without further information. What does file *.rdf | od -c show you? Janis Janis Papanagnou wrote: > On 16.10.2012 16:06, Adam Funk wrote: >> I've just used the file command on four files of RDF-XML with the >> following output: >> >> augtfidf.rdf: XML document text >> kyoto.rdf: XML document text >> stuff.rdf: XML document text >> tfidf.rdf: XML document text >> >> What does it mean that one ...

Non-XML tagged value text to XML
I would like to use XSLT to translate some tagged value text to XML elements like this: Input Doc: <data>x=1.234 y=ABC z="Hello World"</data> Output Doc: <x>1.234</value> <y>ABC</y> <z>&quot;Hello World&quot;</z> Is XSLT up to the task? What would it look like? Most of the XSLT string processing code I've seen looks very verbose - can't be too efficient. mikea_59 wrote: > I would like to use XSLT to translate some tagged value text to XML > elements like this: > > Input Doc: > > <data>x=1.234 y=ABC z="Hello World"</data> > > Output Doc: > > <x>1.234</value> > <y>ABC</y> > <z>&quot;Hello World&quot;</z> > > Is XSLT up to the task? What would it look like? Most of the XSLT > string processing code I've seen looks very verbose - can't be too > efficient. Using XSLT 2.0 you can do that with regular expression matching as follows: <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="2.0"> <xsl:output method="xml" encoding="UTF-8" indent="yes" /> <xsl:template match="/"> <results> <xsl:apply-templates /> </results> </xsl:template> <xsl:template match="data"...

xml wrongly views as text extracted from the xml tags
we have a java framework, where we feed a request xml. this request xml is forwarded through the framework, tomcat and axis, for the backend processing, and the processing results are again received by the internet explorer, after they are transformed with an xslt by the framework. now the problem that we are facing is like - the explorer extracts the text inside all xml tags of the response xml and shows it as simple text. but, if you view the source of the 'text', it will show it all as well-formed xml. moreover, if you save the source as an xml file, and again open it through internet explorer, it will show the xml in proper way. i have tried using firefox, processing with xml spy, but with same results... has somebody experienced similar problem before??? i wonder what can be wrong in this case, and would be thankful for any pointers as to what can be the cause and solution to this. Thanks in advance, Shreyas Hi all, Finally i got what was the problem. it was because the response xml contained a <Title> </Title> tag in it. and dont know why/how, but IE was treating it as an HTML tag. i noticed that the browser window title was indeed "Mr" which is the text enclosed by the Title element. one more weird thing i noticed was that if i moved the <xsl:apply-templates> line for the tag downwords after one more template application, it was showing the xml properly alongwith the <Title> element, and not treating it as an HTML tag...

Help on including one XML document within another XML document using XML Schemas
Hi I would like to specify an XML schema that would allow an XML document to be included within another XML document. The following example schema gives an idea of what we're trying to achieve ServiceResponse.xsd -------------------- <?xml version="1.0" encoding="UTF-8"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified"> <xs:element name="serviceResponse" type="ServiceResponse"/> <xs:complexType name="ServiceResponse"> <xs:sequence> <xs:element name="anXMLDocument" type="xs:string"/> <xs:element name="someOtherData" type="xs:string"/> </xs:sequence> </xs:complexType> </xs:schema> The element anXMLDocument would contain an XML data string that would be parsed against a different XML Schema. The identity of the XML Schema for parsing anXMLDocument is not known at the time the ServiceResponse XML is parsed. Previously when we used DTDs we used inline CDATA wrappers around the contained XML document to avoid it being parsed. Can we still continue to use inline CDATA wrappers around the XML data when we parse against XML schemas? I've tried looking into the XML Schema specs but the mention of CDATA seems a bit sparse and doesn't seem to answer the question. If we can't use an inline CDATA wrapper i...

web.xml / XML schema issue, why do some XML schema attributes disappear
Hi I'm trying to get my j2ee app to run on Jboss (version 3.2.3), but Jboss complains there are some missing attributes in the web-app element. The attributes are present in the XML file, but they seem to be removed by the parser, also when I view the file in a web browser. My XML below (I have cut out a lot of stuff for the purpose of this post) <?xml version="1.0" encoding="ISO-8859-1"?> <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd"> <web-app xmlns="...

Example of an XML document with an inline xml schema
Hi All, I'm looking for a little example of an xml document which is validated using an inline xml schema. I'm a bit of a newbie, and I'm finding this to be a bit of a mind bender, so an example or some pointers which show me how to achieve this would be much appreciated. I look forward to any help or advice any one can offer. Naran Here's a trivial example <arbitrarytag xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="#local"> <xs:schema id="local"> <xs:element name="root" type="xs:integer"/> </xs:schema> <root>35a</root> </arbitrarytag> At least XSV [1] will process this in the desired way. ht [1] http://www.ltg.ed.ac.uk/~ht/xsv-status.html -- Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh Half-time member of W3C Team 2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440 Fax: (44) 131 650-4587, e-mail: ht@inf.ed.ac.uk URL: http://www.ltg.ed.ac.uk/~ht/ [mail really from me _always_ has this .sig -- mail without it is forged spam] http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnxmlnet/html/inlschma.asp -- Stan Kitsis Program Manager, XML Technologies Microsoft Corporation This posting is provided "AS IS" with...

Validating parsed XML document against XML-schema
*PROBLEM: how to validate parsed XML document against (parsed) XML-schema. *IN: XML document as org.w3c.dom.Document, XML-schema as stream *OUT: information if document is valid against schema. If document is not valid DETAILED information about ALL errors (especially: node that caused problem). *Additional information: - validation is performed quite often, - XML-document object is changed quite often, - XML-Schema is fixed. - XML-document doesn't contain information about related XML-schema (attr xsi:noNamespaceSchemaLocation) - XML-Sche...

q) XML Schema and valid XML documents
Wikipedia provides the following definition for valid XML document (http://en.wikipedia.org/wiki/XML): it contains a reference to a Document Type Definition (DTD), and that its elements and attributes are declared in that DTD and follow the grammatical rules for them that the DTD specifies. There is no reference to XML Schema in the above defintion. I am presuming that this is a dated definition for valid XML document and that an XML document that has an XML Schema associated with it is also a valid XML document. Kindly confirm. Thanks, Ramesh In article &l...

XML Schema to XML Schema Conversion
Subject: XML Schema to XML Schema Conversion I have an XML Schema A which needs to mapped to another XML Schema B. Is there any handy tool which I could use to convert from Schema A to Schema B? Any related informaiton on this is appreciated. Thanks! XML Schema's represent the overall structure of your xml document. So if you want a different schema, you should create it. If you have commonality between the two schema's then you should think of putting that commonality in another schema and import that schema to your other schemas.. ie. if Schema A and Schema B have common features, create Schema C import Schema C into both Schema A and Schema B. about transforming one schema to another, there is the XSLT transformation which possibly could do this (since XSD is itself an XML document) but i havent that myself. Stylus Studio is something that you may want to use to play with this. "Hari Om" <hari_om@hotmail.com> wrote in message news:d1d5ebe4.0403021238.4175e63f@posting.google.com... > Subject: XML Schema to XML Schema Conversion > > I have an XML Schema A which needs to mapped to another XML Schema B. > Is there any handy tool which I could use to convert from Schema A to > Schema B? > > Any related informaiton on this is appreciated. > > Thanks! ...

convert text documents to XML
hello sir i am shaji from kerala india. i am a programmer. i hve one doubt i will explain below. we have to devolop a literatures database. i need to include varoius features like search by author,search title, search by publication year etc:- so what we noramlly doing is first store all the literature details to datbase(it includes foolwing information like author(Au),title(TI),abstract( Ab) ,published year etc-: in order to store the these information we need to create one literature entry form...and store the details via form... this method is possible... it is very tedoius since we have around 6000 literaturees are there. so is there any other method? we are downloding these literatures from some external websites...all the literatures are in the same format ...i am sending the litertures record forma below...please check that ... [in the below record format TI:means title AU means author AB:abstract KW means Keywords PY means publication year etc: please check below records...and suggest any new methods. can we convert it into xml directly? literature Record format Record: 1 TI- A Survey of Phytophthora Species on Hainan Island of South China. AU- Hui-cai Zeng1 AU- Hon-hing Ho2 hoh@newpaltz.edu AU- Fuy-Cong Zheng3 JN- Journal of Phytopathology PD- Jan2009, Vol. 157 Issue 1, p33-39 PG- 7p DT- 20090101 PT- Article AB- During the period 1997=962007, a comprehensive study of the occurrence and distribution of Phytophthora species was conducted on Ha...

How do I color text with XML tags?
I am trying to display some XML-tagged text in a web page. The following example works well in Netscape 7.1, but only the H2 heading is colored in MSIE. It seems that MSIE only applies style attributes to tags that it recognizes. Is there a way in which this can be done? Is it possible to format the XML part (from <azTagger> to </azTagger>) with XLS? If so, how? Thanks xyz ======== START OF HTML FILE =========== <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>test</title> <style ...

XML DOM: XML/XHTML inside a text node
In my program, I get input from the user and insert it into an XHTML document. Sometimes, this input will contain XHTML, but since I'm inserting it as a text node, xml.dom.minidom escapes the angle brackets ('<' becomes '&lt;', '>' becomes '&gt;'). I want to be able to override this behavior cleanly. I know I could pipe the input through a SAX parser and create nodes to insert into the tree, but that seems kind of messy. Is there a better way? Thanks. On Thu, 2 Nov 2005 noahlt@gmail.com wrote: > In my program, I get input from the us...

Transfer XML schema to XML document in PL/SQL
Hi guys, I have a problem with xml in PL/SQL I am getting an xml schema from an stored prodedure, and supposed to use it to generate the new xml document(step1) and hardcode some values for some of the nodes inside the document(step2). Can anyone give me a hand on both steps? Really appreciated for any help in advance :) Jun wrote: > Hi guys, > > I have a problem with xml in PL/SQL > I am getting an xml schema from an stored prodedure, and supposed > to > use it to generate the new xml document(step1) and hardcode some values > for some > o...

To XML or not to XML?
Ok, it has been a while since I've needed to make an involved web page. Coming back on the scene now is a bit confusing, what with all the cool stuff to use like XML, PHP, MySQL, etc... So here is my question. I'm in search of a good dynamic way to generate web pages which separates content from presentation. I am seeking to create a web site that, to put it succinctly, has a list of users and sets of information corresponding to each user. I am familiar with how to do this using PHP, MySQL, and regular old HTML. I maintain the user database in MySQL and dynamically present it and the information with PHP. This is very easy to do in terms of coding for it. But I'm wondering? Is it time for me to switch to the XML with XSL method instead? Everyone seems to be talking of XML as the end all be all. I've looked into it, and on the surface, I just can't tell if it's worth it. I don't really see the benefit. XML is just a "create your own HTML tags" and then figure out wtf to do with them orgy. Great, so I can write <dog>Spot</dog>. Whoop de do, that's useless to me unless I write a parser for it to display it in a user friendly way. And I shouldn't have to write a parser, there should be standardized ones for certain purposes. But wait, isn't that what HTML already is? A bunch of <dog>Spot</dog> (figuratively speaking) with the parsers having been written and mostly standardized between companies ages ago...

Change to the public schema document for the XML namespace (xml.xsd)
The schema document at http://www.w3.org/2001/xml.xsd has changed, in order to (belatedly) track the change to xml:lang in XML 3rd edition [1], which now allows the empty string as well as a language code. Per the standard change policy, the old version is still available [2] and will not be changed. A copy of the new version which will never change is also available [3]. ht, on behalf of the W3C XML Core Working Group [followups to public-xml-core-wg@w3.org, please] [1] http://www.w3.org/TR/REC-xml/#sec-lang-tag [2] http://www.w3.org/2004/10/xml.xsd [3] http://www.w3.org/2005/08/xml.xsd -- Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh Half-time member of W3C Team 2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440 Fax: (44) 131 650-4587, e-mail: ht@inf.ed.ac.uk URL: http://www.ltg.ed.ac.uk/~ht/ [mail really from me _always_ has this .sig -- mail without it is forged spam] ...

XML and text positions in original document
Hello!There is a score of really good HTML/XML-parsers around. But I need aDOM representation where every Node points to row/column positions ofthe original text.Example XML:<html> <body> <p>Test</p> </body></html>After parsing Java should be able to render something like along theline:Element pElement = (Element) XmlUtil.getNode(htmlDoc, "html/body/p");int srow = pElement.getStartRow(); //would render 3int scol = pElement.getStartColumn(); //would render 5int erow = pElement.getEndRow(); //would render 3int ecol = pElement.getEndColumn(); //w...

XML to XML
I have a gnucash file that I'm trying to transform into an identical XML file without the invoices. I've been at this for a while now. The gnucash file is in XML and the element I'm looking into is: <gnc:transaction> I want to ignore those that contain <slot:key>gncInvoice</slot:key> which is a child of slot which is a child of slots which is a child of transactions. Any help you're willing to provide would be greatly appreciated. Thanks. Classic application for XSLT. Start with the identity transformation, then add a template which matches the ones you want to treat specially and yields no output. From your description that would be match="gnc:transaction[transactions/slots/slot/slot:key='gncInvoice']" with the namespaces declared appropriately in the stylesheet. (That looks like a somewhat unlikely markup design to me, but since I haven't played with gnucash at all I'm taking your word for it.) -- () ASCII Ribbon Campaign | Joe Kesselman /\ Stamp out HTML e-mail! | System architexture and kinetic poetry Actually, from the Relax-NG schema for gnucash, it looks like it should be more like "gnc:transaction[trn:slots/slot/slot:key='gncInvoice']" with gnc:, trn:, and slot: all bound to the appropriate namespace URIs. The fact that some of their elements -- eg <slot> -- aren't in any namespace is probably left over from a pre-namespaces initial design, as is their now-brok...

XML or not XML?
I am developing a simple MySQL database editor, and am looking into creating an PHP/AJAX app as the GUI. A lot of this in new ground, and much more is dusting off things I haven't used in a while. My question though involves whether or nor to employ XML. I did some XML a few years back, but don't typically bother anymore. As I see it XML is great when I need to have an app with a standard data presentation that other developers can easily interface. I.E. like a bank statement that may feed a variety of applications developed by a variety of clients. However, if I am develo...

text-text
Wondering how what I input to my UTF-8 terminal gets passed along through my patched [1] trn ... Cyrillic: А Б В Г Д Е Ж З И Й К Л М Н О П а б в г д е ж з и й к л м н о п IPA: ᴀ ᴁ ᴂ ᴃ ᴄ ᴅ ᴆ ᴇ ᴈ ᴉ ᴊ ᴋ ᴌ ᴍ ᴎ ᴏ ɀ Ɂ ɂ Ƀ Ʉ Ʌ Ɇ ɇ Ɉ ɉ Ɋ ɋ Ɍ ɍ Ɏ ɏ [1] https://groups.google.com/d/msg/comp.sys.raspberry-pi/7Z37Hdrm0DM/6aqD-reXFzAJ ...

XML Schema for Node with attribute and text
I've tried to find how to write a schema for this type of node everywhere. <Param name="FirstParam">ABCD</Param> How do i arrange a complex type that contains an attribute and a text. This : <xs:complexType name="Param"> <xs:attribute name="name" /> </xs:complexType> Result as : <invalid char="13" code="cvc-complex-type.1.2" line="3086" resource="file:///C:/WINNT/Profiles/svaillan/Desktop/XML Schema/test.xml">element Param must be empty but is not</invalid> This : <xs:complexType name="Param"> <xs:all> <xs:element name="text" type="xs:string" /> </xs:all> <xs:attribute name="name" /> </xs:complexType> Result as : <invalid char="13" code="cvc-complex-type.1.2.3" line="3086" resource="file:///C:/WINNT/Profiles/svaillan/Desktop/XML Schema/test.xml">text not allowed: |ABCD|</invalid> I just dont know where to add the unnamed <xs:element ... > tag. Anyone can help me figure this out? Thx In article <de3c2ad2.0311281339.e74b69b@posting.google.com>, Simon Vaillancourt <svaillancourt@mediagrif.com> wrote: % I've tried to find how to write a schema for this type of node % everywhere. % % <Param name="FirstParam">ABCD</Param> % % How do...

text + text
What is "text + text" supposed to do right now? It doesn't seem very useful to me. What about making "text + text" as an equivalent for "text || text"? Most strongly-typed programming languages do this. And MS SQL Server too, I think (CMIIW). -- dave ---------------------------(end of broadcast)--------------------------- TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org Am Freitag, 8. Oktober 2004 12:57 schrieb David Garamond: > What is "text + text" supposed to do right now? Nothing. > What about making "text + text" as an equivalent for "text > || text"? Most strongly-typed programming languages do this. And MS SQL > Server too, I think (CMIIW). What would this gain except for bloat? It's not like SQL is utterly compatible with any programming language; users will still have to learn all the operators anyway. -- Peter Eisentraut http://developer.postgresql.org/~petere/ ---------------------------(end of broadcast)--------------------------- TIP 9: the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match Peter Eisentraut wrote: >>What is "text + text" supposed to do right now? > > Nothing. Then are these bugs? (7.4.5 and 8.0.0beta1 give same results). Frankly, the current behaviour is quite strange to me. ------------------ =...

Refer to an XML document from within an XML document
Is there an "XML" way to reference an XML document from within an XML document? How do I do this? TIA, - Manish Manish Hatwalne wrote: > Is there an "XML" way to reference an XML document from within an XML > document? How do I do this? XLink: http://www.w3.org/TR/xlink/ XPointer framework: http://www.w3.org/TR/xptr-framework/ http://www.w3.org/TR/xptr-element/ XInclude: http://www.w3.org/TR/xinclude/ Check out yourself which of them comes close to what you understand "reference an XML document" to do. -- Martin Honnen http://JavaScript.FAQTs.com/ ...

converting a document node and children into xml text
is there a way in javascript to convert a DOM node (and it's children) into an XML text. i'd like to save the text file somewhere and then later parse it to re-create the tree. thx. jman, google grouper, wrote: > is there a way in javascript to convert a DOM node (and it's children) > into an XML text. Yes. Traverse the DOM node subtree and output XML accordingly. > i'd like to save the text file somewhere and then later parse it > to re-create the tree. Why? jman wrote: > is there a way in javascript to convert a DOM node (and it's children) > ...

converting xml forrest documents to simple text
Hi, I'm an apache forrest user. So i have written some documents using document-v12.dtd format. I have built a nice web site using forrest. Now i need to convert my xml documents in simple text format. So did anyone knows how to convert my document to text, is there an existing style sheet or any tool? Thanks. ...

Web resources about - XML-tagging text document from W3C-schema - comp.text.xml

Resources last updated: 3/13/2016 10:54:38 PM