<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[SAX2 mehere eintraege]]></title><description><![CDATA[<p>heiho</p>
<p>ich lern zZt den SAX2 teil von xerces, und ich fummel hier schon seit stunden an einem problem herum</p>
<p>das sind die dateien:</p>
<p>person.xml</p>
<pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;iso-8859-1&quot;?&gt;
&lt;person xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot; xsi:noNamespaceSchemaLocation=&quot;person.xsd&quot;&gt;
	&lt;name&gt;Max Mustermann&lt;/name&gt;
	&lt;strasse_nr&gt;Musterstrasse 12&lt;/strasse_nr&gt;
	&lt;plz_ort&gt;12345 Musterhausen&lt;/plz_ort&gt;
	&lt;dsl_anschluss&gt;ja&lt;/dsl_anschluss&gt;
	&lt;email&gt;Max@Mustermann.de&lt;/email&gt;
	&lt;telefon&gt;0123123456&lt;/telefon&gt;
&lt;/person&gt;
</code></pre>
<p>person.xsd<br />
(hab diese datei hier mal um die *_type typen gekuerzt)</p>
<pre><code>&lt;?xml version=&quot;1.0&quot;?&gt;
&lt;xs:schema xmlns:xs=&quot;http://www.w3.org/2001/XMLSchema&quot;&gt;
&lt;xs:element name=&quot;person&quot;&gt;
	&lt;xs:complexType&gt;
		&lt;xs:sequence&gt;
			&lt;xs:element name=&quot;name&quot; type=&quot;name_type&quot;/&gt;
			&lt;xs:element name=&quot;strasse_nr&quot; type=&quot;strasse_nr_type&quot;/&gt;
			&lt;xs:element name=&quot;plz_ort&quot; type=&quot;plz_ort_type&quot;/&gt;
			&lt;xs:element name=&quot;dsl_anschluss&quot; type=&quot;dsl_anschluss_type&quot;/&gt;
			&lt;xs:element name=&quot;email&quot; type=&quot;email_type&quot;/&gt;
			&lt;xs:element name=&quot;telefon&quot; type=&quot;telefon_type&quot;/&gt;
		&lt;/xs:sequence&gt;
	&lt;/xs:complexType&gt;
&lt;/xs:element&gt;
</code></pre>
<p>was ich schon seit ewigkeiten versucht ist indem ich ein zweites &quot;&lt;person&gt;&quot; hinzufuegen will</p>
<pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;iso-8859-1&quot;?&gt;
&lt;person xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot; xsi:noNamespaceSchemaLocation=&quot;person.xsd&quot;&gt;
	&lt;name&gt;Max Mustermann&lt;/name&gt;
	&lt;strasse_nr&gt;Musterstrasse 12&lt;/strasse_nr&gt;
	&lt;plz_ort&gt;12345 Musterhausen&lt;/plz_ort&gt;
	&lt;dsl_anschluss&gt;ja&lt;/dsl_anschluss&gt;
	&lt;email&gt;Max@Mustermann.de&lt;/email&gt;
	&lt;telefon&gt;0123123456&lt;/telefon&gt;
&lt;/person&gt;
&lt;!-- Error
&lt;person xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot; xsi:noNamespaceSchemaLocation=&quot;person.xsd&quot;&gt;
	&lt;name&gt;Max Mustermann&lt;/name&gt;
	&lt;strasse_nr&gt;Musterstrasse 12&lt;/strasse_nr&gt;
	&lt;plz_ort&gt;12345 Musterhausen&lt;/plz_ort&gt;
	&lt;dsl_anschluss&gt;ja&lt;/dsl_anschluss&gt;
	&lt;email&gt;Max@Mustermann.de&lt;/email&gt;
	&lt;telefon&gt;0123123456&lt;/telefon&gt;
&lt;/person&gt;
--&gt;
&lt;!-- Error
&lt;person&gt;
	&lt;name&gt;Max Mustermann&lt;/name&gt;
	&lt;strasse_nr&gt;Musterstrasse 12&lt;/strasse_nr&gt;
	&lt;plz_ort&gt;12345 Musterhausen&lt;/plz_ort&gt;
	&lt;dsl_anschluss&gt;ja&lt;/dsl_anschluss&gt;
	&lt;email&gt;Max@Mustermann.de&lt;/email&gt;
	&lt;telefon&gt;0123123456&lt;/telefon&gt;
&lt;/person&gt;
--&gt;
</code></pre>
<p>wie muesste ich die sxd preparieren damit der SAX2 parser da keine exception wirft ?<br />
bin da etwas durcheinander, in mein lehrbuch wurde nur mit einem person type gearbeitet</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/176123/sax2-mehere-eintraege</link><generator>RSS for Node</generator><lastBuildDate>Sun, 05 Jul 2026 06:22:26 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/176123.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 17 Mar 2007 21:22:50 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to SAX2 mehere eintraege on Sat, 17 Mar 2007 21:22:50 GMT]]></title><description><![CDATA[<p>heiho</p>
<p>ich lern zZt den SAX2 teil von xerces, und ich fummel hier schon seit stunden an einem problem herum</p>
<p>das sind die dateien:</p>
<p>person.xml</p>
<pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;iso-8859-1&quot;?&gt;
&lt;person xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot; xsi:noNamespaceSchemaLocation=&quot;person.xsd&quot;&gt;
	&lt;name&gt;Max Mustermann&lt;/name&gt;
	&lt;strasse_nr&gt;Musterstrasse 12&lt;/strasse_nr&gt;
	&lt;plz_ort&gt;12345 Musterhausen&lt;/plz_ort&gt;
	&lt;dsl_anschluss&gt;ja&lt;/dsl_anschluss&gt;
	&lt;email&gt;Max@Mustermann.de&lt;/email&gt;
	&lt;telefon&gt;0123123456&lt;/telefon&gt;
&lt;/person&gt;
</code></pre>
<p>person.xsd<br />
(hab diese datei hier mal um die *_type typen gekuerzt)</p>
<pre><code>&lt;?xml version=&quot;1.0&quot;?&gt;
&lt;xs:schema xmlns:xs=&quot;http://www.w3.org/2001/XMLSchema&quot;&gt;
&lt;xs:element name=&quot;person&quot;&gt;
	&lt;xs:complexType&gt;
		&lt;xs:sequence&gt;
			&lt;xs:element name=&quot;name&quot; type=&quot;name_type&quot;/&gt;
			&lt;xs:element name=&quot;strasse_nr&quot; type=&quot;strasse_nr_type&quot;/&gt;
			&lt;xs:element name=&quot;plz_ort&quot; type=&quot;plz_ort_type&quot;/&gt;
			&lt;xs:element name=&quot;dsl_anschluss&quot; type=&quot;dsl_anschluss_type&quot;/&gt;
			&lt;xs:element name=&quot;email&quot; type=&quot;email_type&quot;/&gt;
			&lt;xs:element name=&quot;telefon&quot; type=&quot;telefon_type&quot;/&gt;
		&lt;/xs:sequence&gt;
	&lt;/xs:complexType&gt;
&lt;/xs:element&gt;
</code></pre>
<p>was ich schon seit ewigkeiten versucht ist indem ich ein zweites &quot;&lt;person&gt;&quot; hinzufuegen will</p>
<pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;iso-8859-1&quot;?&gt;
&lt;person xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot; xsi:noNamespaceSchemaLocation=&quot;person.xsd&quot;&gt;
	&lt;name&gt;Max Mustermann&lt;/name&gt;
	&lt;strasse_nr&gt;Musterstrasse 12&lt;/strasse_nr&gt;
	&lt;plz_ort&gt;12345 Musterhausen&lt;/plz_ort&gt;
	&lt;dsl_anschluss&gt;ja&lt;/dsl_anschluss&gt;
	&lt;email&gt;Max@Mustermann.de&lt;/email&gt;
	&lt;telefon&gt;0123123456&lt;/telefon&gt;
&lt;/person&gt;
&lt;!-- Error
&lt;person xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot; xsi:noNamespaceSchemaLocation=&quot;person.xsd&quot;&gt;
	&lt;name&gt;Max Mustermann&lt;/name&gt;
	&lt;strasse_nr&gt;Musterstrasse 12&lt;/strasse_nr&gt;
	&lt;plz_ort&gt;12345 Musterhausen&lt;/plz_ort&gt;
	&lt;dsl_anschluss&gt;ja&lt;/dsl_anschluss&gt;
	&lt;email&gt;Max@Mustermann.de&lt;/email&gt;
	&lt;telefon&gt;0123123456&lt;/telefon&gt;
&lt;/person&gt;
--&gt;
&lt;!-- Error
&lt;person&gt;
	&lt;name&gt;Max Mustermann&lt;/name&gt;
	&lt;strasse_nr&gt;Musterstrasse 12&lt;/strasse_nr&gt;
	&lt;plz_ort&gt;12345 Musterhausen&lt;/plz_ort&gt;
	&lt;dsl_anschluss&gt;ja&lt;/dsl_anschluss&gt;
	&lt;email&gt;Max@Mustermann.de&lt;/email&gt;
	&lt;telefon&gt;0123123456&lt;/telefon&gt;
&lt;/person&gt;
--&gt;
</code></pre>
<p>wie muesste ich die sxd preparieren damit der SAX2 parser da keine exception wirft ?<br />
bin da etwas durcheinander, in mein lehrbuch wurde nur mit einem person type gearbeitet</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1247499</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1247499</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Sat, 17 Mar 2007 21:22:50 GMT</pubDate></item><item><title><![CDATA[Reply to SAX2 mehere eintraege on Sat, 17 Mar 2007 21:46:59 GMT]]></title><description><![CDATA[<p>und zack war ich wieder zu voreilig, habs hinbekommen, der fehler war das ich eine id vergeben muss</p>
<p>person.xsd<br />
(die simplytype wie vorhin rausgeschnitten)</p>
<pre><code>&lt;?xml version=&quot;1.0&quot;?&gt;  
&lt;xs:schema xmlns:xs=&quot;http://www.w3.org/2001/XMLSchema&quot;&gt;
&lt;xs:element name=&quot;personlist&quot;&gt;
	&lt;xs:complexType&gt;
		&lt;xs:sequence&gt;
			&lt;xs:element name=&quot;person&quot; maxOccurs=&quot;unbounded&quot;&gt;
				&lt;xs:complexType&gt;
					&lt;xs:sequence&gt;
						&lt;xs:element name=&quot;name&quot; type=&quot;name_type&quot;/&gt;
						&lt;xs:element name=&quot;strasse_nr&quot; type=&quot;strasse_nr_type&quot;/&gt;
						&lt;xs:element name=&quot;plz_ort&quot; type=&quot;plz_ort_type&quot;/&gt;
						&lt;xs:element name=&quot;dsl_anschluss&quot; type=&quot;dsl_anschluss_type&quot;/&gt;
						&lt;xs:element name=&quot;email&quot; type=&quot;email_type&quot;/&gt;
						&lt;xs:element name=&quot;telefon&quot; type=&quot;telefon_type&quot;/&gt;
					&lt;/xs:sequence&gt;
					&lt;xs:attribute name=&quot;person_id&quot; type=&quot;xs:ID&quot; use=&quot;required&quot;/&gt;
				&lt;/xs:complexType&gt;
			&lt;/xs:element&gt;
		&lt;/xs:sequence&gt;
	&lt;/xs:complexType&gt;
&lt;/xs:element&gt;
</code></pre>
<p>person.xml</p>
<pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;iso-8859-1&quot;?&gt;
&lt;personlist xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot; xsi:noNamespaceSchemaLocation=&quot;person.xsd&quot;&gt;
	&lt;person person_id=&quot;Max&quot;&gt;
		&lt;name&gt;Max Mustermann&lt;/name&gt;
		&lt;strasse_nr&gt;Musterstr 12&lt;/strasse_nr&gt;
		&lt;plz_ort&gt;12345 Musterhausen&lt;/plz_ort&gt;
		&lt;dsl_anschluss&gt;ja&lt;/dsl_anschluss&gt;
		&lt;email&gt;Max@Mustermann.de&lt;/email&gt;
		&lt;telefon&gt;12345123456&lt;/telefon&gt;
	&lt;/person&gt;
	&lt;person person_id=&quot;Marta&quot;&gt;
		&lt;name&gt;MartaMustermann&lt;/name&gt;
		&lt;strasse_nr&gt;Musterstr 12&lt;/strasse_nr&gt;
		&lt;plz_ort&gt;12345 Musterhausen&lt;/plz_ort&gt;
		&lt;dsl_anschluss&gt;ja&lt;/dsl_anschluss&gt;
		&lt;email&gt;Marta@Mustermann.de&lt;/email&gt;
		&lt;telefon&gt;12345123457&lt;/telefon&gt;
	&lt;/person&gt;
&lt;/personlist&gt;
</code></pre>
<p>danke fuer die aufmerksamkeit</p>
<p>xml is schon cool {=</p>
<p>//dazuedit, geht auch ohne ID, solange<br />
&lt;xs:element name=&quot;person&quot; maxOccurs=&quot;unbounded&quot;&gt;<br />
angegeben ist</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1247506</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1247506</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Sat, 17 Mar 2007 21:46:59 GMT</pubDate></item></channel></rss>