Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

XML Schema Help (XSD isn't working)

Status
Not open for further replies.

strangelad

Programmer
Jan 28, 2009
1
GB
Well, I'll try this again after my first submission crashed Firefox.
I'm currently trying to use SQL Server Integration Services to import a daily 1Gb file, it's provided by a client who use an off the shelf package to dump it out. The XSD's for the package seem to cause MS products no end of grief as they re-use the "key" repeatedly in the same namespace:
<?xml version="1.0" encoding="UTF-8"?>
<rea xmlns="urn:listing" xmlns:rea="urn:rea" xmlns:xsi=" xsi:schemaLocation="urn:listing created="20090108T080043">
<application version="1.0">REAExporter</application>
<source rea:key="Client">
<office key="786461" rea:key="JSDFIJSDJI">
<listing key="757353" status="active" rea:key="786757635" updated="20090102T112905">
<description></description>
<listing key="676678" status="active" rea:key="674567675" updated="20090102T112905">
<description></description>

The schema can be found via the link above, it has a sub schema which is and if you want more sample data it's here ( Basically, I want to know if this is badly formed XML and if I strip this piece of XML (and it's corresponding close tags):

<application version="1.0">REAExporter</application>
<source rea:key="Client">
<office key="786461" rea:key="JSDFIJSDJI">

And change the XSD's accordingly, will it work? As far as I can tell (and it's a 1Gig file which crashes every parser I've tried so far) there is only ever 1 occurrence of the above so it serves no useful purpose.

Cheers.
 
[1] Before you do any editing, maybe you should ask ssis forum see if those memebers have any idea of the "grief" (that I have no idea of what).
Xml source editor is basically a gui application that might be eating too much resource for loading a 1GB source document? Besides, the functioning might not be perfected yet, despite it might be the state-of-the-art for ms at present.

[2] If you are bothered by the key and rea:key attributes of the tags you've shown, you are better off by deleting them rather than the tag itself. The corresponding modification of the xsd's would be much less: just take out those xs:attribute lines of the corresponding complexType(s). Or you might consider renaming them and adding the corresponding new attributes in the schemas.

[3] In any case, further editing the xml and xsd's just to avoid deficiency of mapping function in the xml source editor seems not to be a good idea at all. But I can't say for sure.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top