Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > XML Schema validation

Reply
Thread Tools

XML Schema validation

 
 
Piotre Ugrumov
Guest
Posts: n/a
 
      09-08-2008
Hi,
I have written this xml schema:
<?xml version="1.0" encoding="ISO-8859-1"?>
<xs:schema xmlnss="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://FinDB.xml"
xmlns="http://FinDB.xml"
elementFormDefault="qualified">

<xs:element name="XMLFLOW" type="XMFLOW"/>


<xs:complexType name="XMLFLOW">
<xs:sequence>
<xs:element name="PRODUCT" type="PRODUCT"/>
</xs:sequence>
</xs:complexType>



<xs:complexType name="PRODUCT">
<xs:element name="INFO" type="INFO"/>
<xs:element name="RISK" type="RISK"/>
<xs:element name="VAR" type="VAR"/>
<xs:element name="STOCK" type="STOCK"/>
<xs:element name="BOND" type="BOND"/>
<xs:element name="EMIT" type="EMIT"/>
<xs:element name="GUARANTOR" type="GUARANTOR"/>
<xs:element name="GOVERNANCE" type="GOVERNANCE"/>
<xs:element name="FORMULA" type="FORMULA"/>
</xs:complexType>

<xs:complexType name="INFO">
<xs:element name="ISIN" type="xs:string" />
<xs:element name="DESCRIZIONE_TITOLO" type="xs:string" />
<xs:element name="INSERT_DATE" type="xs:date" />
<xs:element name="TYPE" type="xs:string" />
<xs:element name="EMIT_CODE" type="xs:string" />
<xs:element name="SEGMENT" type="xs:string" />
</xs:complexType>

<xs:complexType name="RISK">
<xs:element name="BUSINESS_DATE" type="xs:date"/>
<xs:element name="AZIONE" type="xs:integer"/>
<xs:element name="CAMBIO" type="xs:integer"/>
<xs:element name="EMITTENTE" type="xs:integer"/>
<xs:element name="OPZIONE" type="xs:integer"/>
<xs:element name="PAESE" type="xs:integer"/>
<xs:element name="TASSO" type="xs:integer"/>
</xs:complexType>

<xs:complexType name="VAR">
<xs:element name="VAR_TRIMESTRALE" type="xs:double"/>
</xs:complexType>

<xs:complexType name="STOCK">
<xs:element name="NUMERO_AZIONI_IN_CIRCOLAZIONE" type="xs:duble"/>
<xs:element name="DATA" type="xs:date" />
<xs:element name="VALUTA" type="xs:string" />
<xs:element name="CAPITALIZZAZIONE" type="xs:duble" />
<xs:element name="CODICE_INDICE" type="xs:integer" />
<xs:element name="DATA_EX_CEDOLA" type="xs:date" />
<xs:element name="RECORD_DATE" type="xs:date" />
<xs:element name="IMPORTO_DIVIDENDO_PAGATO_LORDO" type="xs:duble" /
>

<xs:element name="VALUTA_ULTIMO_DIVIDENDO" type="xs:string" />
<xs:element name="IMP_DIV_ES_RITENUTA_FISC" type="xs:duble" />
<xs:element name="DATA_PAGAMENTO" type="xs:date" />
<xs:element name="FREQUENZA_DIVIDENDO" type="xs:string" />
<xs:element name="VALORE_CAPITALE_SOCIALE" type="xs:integer" />
</xs:complexType>

<xs:complexType name="BOND">
<xs:element name="RATING_TITOLO_MOODYS" type="xs:string" />
<xs:element name="DATA_RATING_TITOLO_MOODYS" type="xs:date" />
<xs:element name="RATING_TITOLO_S" type="xs:string" />
<xs:element name="DATA_RATING_TITOLO_S" type="xs:date" />
<xs:element name="SOTTOSTANTE" type="xs:string" />
<xs:element name="TIPO_SOTTOSTANTE" type="xs:string" />
<xs:element name="CEDOLA_LORDA_CORRENTE" type="xs:duble" />
<xs:element name="FREQUENZA_CEDOLA" type="xs:string" />
<xs:element name="DATA_INIZIO_FACOLTA_CALL" type="xs:date" />
<xs:element name="DATA_FINE_FACOLTA_CALL" type="xs:date" />
<xs:element name="DATA_INIZIO_FACOLTA_PUT" type="xs:date" />
<xs:element name="DATA_FINE_FACOLTA_PUT" type="xs:date" />
<xs:element name="AMMONTARE_EMESSO" type="xs:integer" />
<xs:element name="DATA_PRIMO_GODIMENTO" type="xs:date" />
<xs:element name="DATA_SCADENZA" type="xs:date" />
<xs:element name="PRIMO_PREZZO_EMISSIONE" type="xs:duble" />
<xs:element name="MODALITA_RIMBORSO" type="xs:integer" />
</xs:complexType>

<xs:complexType name="EMIT">
<xs:element name="DESCRIZIONE_EMITTENTE" type="xs:string" />
<xs:element name="INDIRIZZO_SEDE_EMITTENTE" type="xs:string" />
<xs:element name="SOTTOGRUPPO_ATTIVITA_ECONOMICA"
type="xs:string" />
<xs:element name="RAMO_ATTIVITA_ECONOMICA" type="xs:string" />
<xs:element name="GRUPPO_EMITTENTE" type="xs:string" />
<xs:element name="RATING_EMITTENTE_MOODYS" type="xs:string" />
<xs:element name="DATA_RATING_EMITTENTE_MOODYS" type="xs:date" />
<xs:element name="RATING_EMITTENTE_S" type="xs:string" />
<xs:element name="DATA_RATING_EMITTENTE_S" type="xs:date" />
<xs:element name="CAPITALE_SOCIALE_EMITTENTE" type="xs:integer" />
<xs:element name="PROFILO_EMITTENTE" type="xs:string" />
</xs:complexType>

<xs:complexType name="GUARANTOR">
<xs:element name="EMICOD_GARANTE" type="xs:string" />
<xs:element name="DESCRIZIONE_GARANTE" type="xs:string" />
<xs:element name="SEDE_LEGALE_GARANTE" type="xs:string" />
<xs:element name="RATING_GARANTE_MOODYS" type="xs:string" />
<xs:element name="DATA_RATING_GARANTE_MOODYS" type="xs:date" />
<xs:element name="RATING_GARANTE_S" type="xs:string" />
<xs:element name="DATA_RATING_GARANTE_S" type="xs:date" />
<xs:element name="PROFILO_GARANTE" type="xs:date" />
</xs:complexType>

<xs:complexType name="GOVERNANCE">
<xs:element name="TIPO" type="xs:string" />
<xs:element name="CARICA" type="xs:string" />
<xs:element name="NOMINATIVO" type="xs:string" />
<xs:element name="PERCENTUALE" type="xs:duble" />
</xs:complexType>

<xs:complexType name="FORMULA">
<xs:element name="PERIODO" type="xs:string" />
<xs:element name="TIPOLOGIA_CALCOLO_GIORNI" type="xs:string" />
<xs:element name="SPREAD_INIZIALE" type="xs:string" />
<xs:element name="SPREAD_INIZIALE_FUORI_DENTRO" type="xs:string" /
>

<xs:element name="RADICE_PARENTESI" type="xs:string" />
<xs:element name="PARAMETRO_1" type="xs:string" />
<xs:element name="SPREAD_1" type="xs:string" />
<xs:element name="PONDERAZIONE_1" type="xs:string" />
<xs:element name="PARAMETRO_2" type="xs:string" />
<xs:element name="SPREAD_2" type="xs:string" />
<xs:element name="PONDERAZIONE_2" type="xs:string" />
<xs:element name="PARAMETRO_3" type="xs:string" />
<xs:element name="SPREAD_3" type="xs:string" />
<xs:element name="PONDERAZIONE_3" type="xs:string" />
<xs:element name="PARAMETRO_4" type="xs:string" />
<xs:element name="SPREAD_4" type="xs:string" />
<xs:element name="PONDERAZIONE_4" type="xs:string" />
<xs:element name="SPREAD_FINALE_FUORI_DENTRO" type="xs:string" />
<xs:element name="SPREAD_FINALE" type="xs:string" />
<xs:element name="ADJUSTED_UNADJUSTED" type="xs:string" />
<xs:element name="RILEVAZIONE_ANT_POST" type="xs:string" />
<xs:element name="DAY_CONVENTION" type="xs:string" />
<xs:element name="PERIODO_RIL_PARAMETRI" type="xs:string" />
<xs:element name="ARROTONDAMENTO" type="xs:string" />
<xs:element name="NOTA" type="xs:string" />
</xs:complexType>

</xs:schema>

and I want validate this XML document:

<?xml version="1.0" encoding="ISO-8859-1"?>
<XMLFLOW xmlns="http://FinDB.xml"
xmlnssi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://FinDB.xml
SPR_XmlFlow.xsd">
<PRODUCT>
<INFO>
<ISIN>IT0003647176</
ISIN>
<DESCRIZIONE_TITOLO>mi scoccio</
DESCRIZIONE_TITOLO>
<INSERT_DATE>19000904</INSERT_DATE><TYPE>OBB</
TYPE>
<EMIT_CODE>1234567812345678</EMIT_CODE><SEGMENT>TLXX</SEGMENT></
INFO><RISK>
<BUSINESS_DATE>20080910</
BUSINESS_DATE>
<AZIONE>5</
AZIONE>
<CAMBIO>5</
CAMBIO>
<EMITTENTE>4</
EMITTENTE>
<OPZIONE>3</
OPZIONE>
<PAESE>5</
PAESE>
<TASSO>5</TASSO> </
RISK><VAR>
<VAR_TRIMESTRALE>515.616911616162</
VAR_TRIMESTRALE>
</
VAR><STOCK>
<NUMERO_AZIONI_IN_CIRCOLAZIONE>161891196</
NUMERO_AZIONI_IN_CIRCOLAZIONE>
<DATA>20080904</DATA><VALUTA>EUR</
VALUTA>
<CAPITALIZZAZIONE>16161616541616</
CAPITALIZZAZIONE>
<CODICE_INDICE>5555</
CODICE_INDICE>
<DATA_EX_CEDOLA>20080815</DATA_EX_CEDOLA><RECORD_DATE>20080605</
RECORD_DATE>
<IMPORTO_DIVIDENDO_PAGATO_LORDO>5815563</
IMPORTO_DIVIDENDO_PAGATO_LORDO>
<VALUTA_ULTIMO_DIVIDENDO>EUR</
VALUTA_ULTIMO_DIVIDENDO>
<IMP_DIV_ES_RITENUTA_FISC>20202</
IMP_DIV_ES_RITENUTA_FISC>
<DATA_PAGAMENTO>20080725</
DATA_PAGAMENTO>
<FREQUENZA_DIVIDENDO>f</
FREQUENZA_DIVIDENDO>
<VALORE_CAPITALE_SOCIALE>25550</
VALORE_CAPITALE_SOCIALE>
</STOCK><BOND><RATING_TITOLO_MOODYS>asdaesf</
RATING_TITOLO_MOODYS>
<DATA_RATING_TITOLO_MOODYS>20080906</
DATA_RATING_TITOLO_MOODYS>
<RATING_TITOLO_SP>8yuk52</
RATING_TITOLO_SP>
<DATA_RATING_TITOLO_SP>20071225</
DATA_RATING_TITOLO_SP>
<SOTTOSTANTE>5dwasd</
SOTTOSTANTE>
<TIPO_SOTTOSTANTE>dasdfas5</
TIPO_SOTTOSTANTE>
<CEDOLA_LORDA_CORRENTE>965</
CEDOLA_LORDA_CORRENTE>
<FREQUENZA_CEDOLA>f</
FREQUENZA_CEDOLA>
<DATA_INIZIO_FACOLTA_CALL>20080201</
DATA_INIZIO_FACOLTA_CALL>
<DATA_FINE_FACOLTA_CALL>20080829</
DATA_FINE_FACOLTA_CALL>
<DATA_INIZIO_FACOLTA_PUT>20080926</
DATA_INIZIO_FACOLTA_PUT>
<DATA_FINE_FACOLTA_PUT>20080926</
DATA_FINE_FACOLTA_PUT>
<AMMONTARE_EMESSO>555</
AMMONTARE_EMESSO>
<DATA_PRIMO_GODIMENTO>20080920</
DATA_PRIMO_GODIMENTO>
<DATA_SCADENZA>20080815</
DATA_SCADENZA>
<PRIMO_PREZZO_EMISSIONE>5469</
PRIMO_PREZZO_EMISSIONE>
<MODALITA_RIMBORSO>89</
MODALITA_RIMBORSO>
</
BOND><EMIT>
<DESCRIZIONE_EMITTENTE>bellissimo</
DESCRIZIONE_EMITTENTE>
<INDIRIZZO_SEDE_EMITTENTE>via calcestruzzo 18</
INDIRIZZO_SEDE_EMITTENTE>
<SOTTOGRUPPO_ATTIVITA_ECONOMICA>wer</
SOTTOGRUPPO_ATTIVITA_ECONOMICA>
<RAMO_ATTIVITA_ECONOMICA>yan</
RAMO_ATTIVITA_ECONOMICA>
<GRUPPO_EMITTENTE>0</
GRUPPO_EMITTENTE>
<RATING_EMITTENTE_MOODYS>ddsa</
RATING_EMITTENTE_MOODYS>
<DATA_RATING_EMITTENTE_MOODYS>20080705</
DATA_RATING_EMITTENTE_MOODYS>
<RATING_EMITTENTE_SP>er</
RATING_EMITTENTE_SP>
<DATA_RATING_EMITTENTE_SP>20080725</
DATA_RATING_EMITTENTE_SP>
<CAPITALE_SOCIALE_EMITTENTE>52369</
CAPITALE_SOCIALE_EMITTENTE>
<PROFILO_EMITTENTE>alto</
PROFILO_EMITTENTE>
</EMIT><GUARANTOR><EMICOD_GARANTE>8529631478963214</
EMICOD_GARANTE>
<DESCRIZIONE_GARANTE>ma non saprei</
DESCRIZIONE_GARANTE>
<SEDE_LEGALE_GARANTE>via onofrio pirrotta 50</
SEDE_LEGALE_GARANTE>
<RATING_GARANTE_MOODYS>sdd5</
RATING_GARANTE_MOODYS>
<DATA_RATING_GARANTE_MOODYS>20080606</
DATA_RATING_GARANTE_MOODYS>
<RATING_GARANTE_SP>wdew</
RATING_GARANTE_SP>
<DATA_RATING_GARANTE_SP>20080305</
DATA_RATING_GARANTE_SP>
<PROFILO_GARANTE>19180502</PROFILO_GARANTE></
GUARANTOR><GOVERNANCE>
<TIPO>rf</
TIPO>
<CARICA>gffd</
CARICA>
<NOMINATIVO>egerwgf</
NOMINATIVO>
<PERCENTUALE>69</PERCENTUALE>
</GOVERNANCE>
<FORMULA>
<PERIODO>5</
PERIODO>
<TIPOLOGIA_CALCOLO_GIORNI>a</
TIPOLOGIA_CALCOLO_GIORNI>
<SPREAD_INIZIALE>efre</
SPREAD_INIZIALE>
<SPREAD_INIZIALE_FUORI_DENTRO>s</
SPREAD_INIZIALE_FUORI_DENTRO>
<RADICE_PARENTESI>v</
RADICE_PARENTESI>
<PARAMETRO_1>dvdsdv</
PARAMETRO_1>
<SPREAD_1>bfh</SPREAD_1> <PONDERAZIONE_1>bb</
PONDERAZIONE_1>
<PARAMETRO_2>ngfngf</
PARAMETRO_2>
<SPREAD_2>bgdf</SPREAD_2> <PONDERAZIONE_2>xfb</
PONDERAZIONE_2>
<PARAMETRO_3>rgf</
PARAMETRO_3>
<SPREAD_3>dgfsdgv</SPREAD_3> <PONDERAZIONE_3>fs</
PONDERAZIONE_3>
<PARAMETRO_4>dvdb fd</
PARAMETRO_4>
<SPREAD_4>fgh</SPREAD_4> <PONDERAZIONE_4>cc</
PONDERAZIONE_4>
<SPREAD_FINALE_FUORI_DENTRO>v</
SPREAD_FINALE_FUORI_DENTRO>
<SPREAD_FINALE>vddv</
SPREAD_FINALE>
<ADJUSTED_UNADJUSTED>v</
ADJUSTED_UNADJUSTED>
<RILEVAZIONE_ANT_POST>c</
RILEVAZIONE_ANT_POST>
<DAY_CONVENTION>vv</
DAY_CONVENTION>
<PERIODO_RIL_PARAMETRI>cx</
PERIODO_RIL_PARAMETRI>
<ARROTONDAMENTO>rc</ARROTONDAMENTO><NOTA>gh</NOTA></FORMULA></
PRODUCT>
<PRODUCT>
<INFO>
<ISIN>XS0185030698</
ISIN>
<DESCRIZIONE_TITOLO>gia mangiato</
DESCRIZIONE_TITOLO>
<INSERT_DATE>19180904</INSERT_DATE><TYPE>AZI</
TYPE>
<EMIT_CODE>8765432187654321</EMIT_CODE><SEGMENT>EMOT</SEGMENT></
INFO><RISK>
<BUSINESS_DATE>20080904</
BUSINESS_DATE>
<AZIONE>5</
AZIONE>
<CAMBIO>5</
CAMBIO>
<EMITTENTE>3</
EMITTENTE>
<OPZIONE>3</
OPZIONE>
<PAESE>3</
PAESE>
<TASSO>4</TASSO> </
RISK><VAR>
<VAR_TRIMESTRALE>151.58178949489</
VAR_TRIMESTRALE>
</
VAR><STOCK>
<NUMERO_AZIONI_IN_CIRCOLAZIONE>15151515151</
NUMERO_AZIONI_IN_CIRCOLAZIONE>
<DATA>20080904</DATA><VALUTA>USD</
VALUTA>
<CAPITALIZZAZIONE>146165165165</
CAPITALIZZAZIONE>
<CODICE_INDICE>6666</
CODICE_INDICE>
<DATA_EX_CEDOLA>20080828</DATA_EX_CEDOLA><RECORD_DATE>20080508</
RECORD_DATE>
<IMPORTO_DIVIDENDO_PAGATO_LORDO>212122</
IMPORTO_DIVIDENDO_PAGATO_LORDO>
<VALUTA_ULTIMO_DIVIDENDO>USD</
VALUTA_ULTIMO_DIVIDENDO>
<IMP_DIV_ES_RITENUTA_FISC>5555</
IMP_DIV_ES_RITENUTA_FISC>
<DATA_PAGAMENTO>20080425</
DATA_PAGAMENTO>
<FREQUENZA_DIVIDENDO>a</
FREQUENZA_DIVIDENDO>
<VALORE_CAPITALE_SOCIALE>336</
VALORE_CAPITALE_SOCIALE>
</STOCK><BOND><RATING_TITOLO_MOODYS>fdsgf</
RATING_TITOLO_MOODYS>
<DATA_RATING_TITOLO_MOODYS>20080823</
DATA_RATING_TITOLO_MOODYS>
<RATING_TITOLO_SP>85jo2</
RATING_TITOLO_SP>
<DATA_RATING_TITOLO_SP>20071225</
DATA_RATING_TITOLO_SP>
<SOTTOSTANTE>5afdwsf</
SOTTOSTANTE>
<TIPO_SOTTOSTANTE>sfawe3rm3</
TIPO_SOTTOSTANTE>
<CEDOLA_LORDA_CORRENTE>987</
CEDOLA_LORDA_CORRENTE>
<FREQUENZA_CEDOLA>m</
FREQUENZA_CEDOLA>
<DATA_INIZIO_FACOLTA_CALL>20080308</
DATA_INIZIO_FACOLTA_CALL>
<DATA_FINE_FACOLTA_CALL>20080731</
DATA_FINE_FACOLTA_CALL>
<DATA_INIZIO_FACOLTA_PUT>20080926</
DATA_INIZIO_FACOLTA_PUT>
<DATA_FINE_FACOLTA_PUT>20080913</
DATA_FINE_FACOLTA_PUT>
<AMMONTARE_EMESSO>4444</
AMMONTARE_EMESSO>
<DATA_PRIMO_GODIMENTO>20080922</
DATA_PRIMO_GODIMENTO>
<DATA_SCADENZA>20080801</
DATA_SCADENZA>
<PRIMO_PREZZO_EMISSIONE>6321</
PRIMO_PREZZO_EMISSIONE>
<MODALITA_RIMBORSO>12</
MODALITA_RIMBORSO>
</
BOND><EMIT>
<DESCRIZIONE_EMITTENTE>brutto come la morte</
DESCRIZIONE_EMITTENTE>
<INDIRIZZO_SEDE_EMITTENTE>via dei matti 0</
INDIRIZZO_SEDE_EMITTENTE>
<SOTTOGRUPPO_ATTIVITA_ECONOMICA>jin</
SOTTOGRUPPO_ATTIVITA_ECONOMICA>
<RAMO_ATTIVITA_ECONOMICA>tut</
RAMO_ATTIVITA_ECONOMICA>
<GRUPPO_EMITTENTE>1</
GRUPPO_EMITTENTE>
<RATING_EMITTENTE_MOODYS>65g</
RATING_EMITTENTE_MOODYS>
<DATA_RATING_EMITTENTE_MOODYS>20080606</
DATA_RATING_EMITTENTE_MOODYS>
<RATING_EMITTENTE_SP>5h</
RATING_EMITTENTE_SP>
<DATA_RATING_EMITTENTE_SP>20080525</
DATA_RATING_EMITTENTE_SP>
<CAPITALE_SOCIALE_EMITTENTE>98745</
CAPITALE_SOCIALE_EMITTENTE>
<PROFILO_EMITTENTE>quello sinistro e meglio</
PROFILO_EMITTENTE>
</EMIT><GUARANTOR><EMICOD_GARANTE>1234567812345678</
EMICOD_GARANTE>
<DESCRIZIONE_GARANTE>mutande</
DESCRIZIONE_GARANTE>
<SEDE_LEGALE_GARANTE>via cimabue 2</
SEDE_LEGALE_GARANTE>
<RATING_GARANTE_MOODYS>fed6</
RATING_GARANTE_MOODYS>
<DATA_RATING_GARANTE_MOODYS>20080401</
DATA_RATING_GARANTE_MOODYS>
<RATING_GARANTE_SP>uui</
RATING_GARANTE_SP>
<DATA_RATING_GARANTE_SP>20080327</
DATA_RATING_GARANTE_SP>
<PROFILO_GARANTE>19150620</PROFILO_GARANTE></
GUARANTOR><GOVERNANCE>
<TIPO>yu</
TIPO>
<CARICA>sdf</
CARICA>
<NOMINATIVO>4ewryj</
NOMINATIVO>
<PERCENTUALE>526</PERCENTUALE> </
GOVERNANCE>
<FORMULA><PERIODO>9</
PERIODO>
<TIPOLOGIA_CALCOLO_GIORNI>M</
TIPOLOGIA_CALCOLO_GIORNI>
<SPREAD_INIZIALE>safr</
SPREAD_INIZIALE>
<SPREAD_INIZIALE_FUORI_DENTRO>l</
SPREAD_INIZIALE_FUORI_DENTRO>
<RADICE_PARENTESI>j</
RADICE_PARENTESI>
<PARAMETRO_1>vcxbvdf</
PARAMETRO_1>
<SPREAD_1>bvcv</SPREAD_1> <PONDERAZIONE_1>bb</
PONDERAZIONE_1>
<PARAMETRO_2>bdf ndcbx</
PARAMETRO_2>
<SPREAD_2>xcbb</SPREAD_2> <PONDERAZIONE_2>cvb</
PONDERAZIONE_2>
<PARAMETRO_3>dvgdbfb</
PARAMETRO_3>
<SPREAD_3>vgsdv</SPREAD_3> <PONDERAZIONE_3>tg</
PONDERAZIONE_3>
<PARAMETRO_4>vdevvvv</
PARAMETRO_4>
<SPREAD_4>iuy</SPREAD_4> <PONDERAZIONE_4>cc</
PONDERAZIONE_4>
<SPREAD_FINALE_FUORI_DENTRO>a</
SPREAD_FINALE_FUORI_DENTRO>
<SPREAD_FINALE>vvv</
SPREAD_FINALE>
<ADJUSTED_UNADJUSTED>u</
ADJUSTED_UNADJUSTED>
<RILEVAZIONE_ANT_POST>a</
RILEVAZIONE_ANT_POST>
<DAY_CONVENTION>iu</
DAY_CONVENTION>
<PERIODO_RIL_PARAMETRI>zp</
PERIODO_RIL_PARAMETRI>
<ARROTONDAMENTO>gh</ARROTONDAMENTO><NOTA>vd</NOTA></FORMULA></
PRODUCT>
</XMLFLOW>

When I try to validate the document I receive these errors:

Validation 7, 43 src-resolve: Cannot resolve the name 'XMFLOW' to
a(n) 'type definition' component.
Validation 19, 41 s4s-elt-invalid-content.1: The content of
'PRODUCT' is invalid. Element 'element' is invalid, misplaced, or
occurs too often.
Validation 31, 48 s4s-elt-invalid-content.1: The content of 'INFO'
is invalid. Element 'element' is invalid, misplaced, or occurs too
often.
Validation 40, 53 s4s-elt-invalid-content.1: The content of 'RISK'
is invalid. Element 'element' is invalid, misplaced, or occurs too
often.
Validation 50, 57 s4s-elt-invalid-content.1: The content of 'VAR' is
invalid. Element 'element' is invalid, misplaced, or occurs too often.
Validation 54, 70 s4s-elt-invalid-content.1: The content of 'STOCK'
is invalid. Element 'element' is invalid, misplaced, or occurs too
often.
Validation 70, 64 s4s-elt-invalid-content.1: The content of 'BOND'
is invalid. Element 'element' is invalid, misplaced, or occurs too
often.
Validation 90, 65 s4s-elt-invalid-content.1: The content of 'EMIT'
is invalid. Element 'element' is invalid, misplaced, or occurs too
often.
Validation 104, 59 s4s-elt-invalid-content.1: The content of
'GUARANTOR' is invalid. Element 'element' is invalid, misplaced, or
occurs too often.
Validation 115, 49 s4s-elt-invalid-content.1: The content of
'GOVERNANCE' is invalid. Element 'element' is invalid, misplaced, or
occurs too often.
Validation 122, 52 s4s-elt-invalid-content.1: The content of
'FORMULA' is invalid. Element 'element' is invalid, misplaced, or
occurs too often.

Why?
How can I solve?
Thanks, bye bye.
 
Reply With Quote
 
 
 
 
usenet@tech-know-ware.com
Guest
Posts: n/a
 
      09-10-2008
On 8 Sep, 10:46, Piotre Ugrumov <(E-Mail Removed)> wrote:
> Hi,
> I have written this xml schema:
>
> ... cut ...
>
> When I try to validate the document I receive these errors:
>
> Validation * * *7, 43 * src-resolve: Cannot resolve the name 'XMFLOW' to
> a(n) 'type definition' component.


There's a typo there. In:

<xs:element name="XMLFLOW" type="XMFLOW"/>
<xs:complexType name="XMLFLOW">

type="XMFLOW" should go to type="XMLFLOW".

> Validation * * *19, 41 *s4s-elt-invalid-content.1: The content of
> 'PRODUCT' is invalid. Element 'element' is invalid, misplaced, or
> occurs too often.


The syntax for the complexTypes is wrong. It should be something
like:

<xs:complexType name="PRODUCT">
<xs:sequence> <!-- This is added -->
<xs:element name="INFO" type="INFO"/>
...
</xs:sequence>
</xs:complexType>

HTH,

Pete Cordell
Codalogic Ltd
Interface XML to C++ the easy way using XML C++
data binding to convert XSD schemas to C++ classes.
Visit http://www.codalogic.com/lmx/ for more info


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
New to xml schema - does the dtd/schema validation happens always ? pramodr XML 3 04-05-2009 12:10 PM
web.xml / XML schema issue, why do some XML schema attributes disappear asciz@starmail.com Java 3 02-20-2007 09:56 AM
Validation with XSD using XML::LibXML::Schema, and XML::Validator::Schema huntingseasonson@gmail.com Perl Misc 5 11-29-2006 12:37 PM
Problem with schema-validation and property "http://apache.org/xml/properties/schema/external-schemaLocation" Markus Java 1 11-23-2005 02:41 PM
[XML Schema] Including a schema document with absent target namespace to a schema with specified target namespace Stanimir Stamenkov XML 3 04-25-2005 09:59 AM



Advertisments