Solved

Tool to validate and generate DTD, Schema from a XML document large in size

Posted on 2009-05-05
9
255 Views
Last Modified: 2012-05-06
HI experts,
                  I am looking for a tool that could generate DTD and schema from an XMl document, right now I am using XMLspy but its running out of memory as soon as I try to generate XML schema or DTD.

                  The XML file size I am dealing with is aroung 160mb
     
0
Comment
Question by:aman0711
  • 5
  • 4
9 Comments
 
LVL 60

Assisted Solution

by:Geert Bormans
Geert Bormans earned 500 total points
ID: 24308497
well, the IDE itself is taking away too much of your available memory.

I have used this before
http://www.thaiopensource.com/relaxng/trang.html

I have not tested that on such large files, but it has no problem with things in the 40MB range, that I know
Maybe if you give it enough heapspace...

On the other hand, if you have a 160MB file, I bet there is a lot of repetition in there,
try cutting it, it will likely not have an effect on the schema if you derive a schema from a subset of the file
0
 
LVL 10

Author Comment

by:aman0711
ID: 24308535
Hi Gertone,
                     I am very new to all this.... Is it real tough to use trang??

                     
0
 
LVL 60

Accepted Solution

by:
Geert Bormans earned 500 total points
ID: 24308592
no, it is easy

make sure you have a java virtual machine and then you can do...
java -jar trang.jar args

it is all in the manual

I mainly use Trang inside an IDE (www.oxygenxml.com)
That is even easier, but it will give you the same memory problems.
That is why I suggest using the command line version of it

What is not in the manual is increasing the heapspace
java -Xms1024M -Xmx1024M  -jar trang.jar args

Make sure you have at least a gigabyte free for this in RAM

But seriously...
cut the file in pieces, make a schema for each piece and compare
it will be a lot better



0
 
LVL 10

Author Comment

by:aman0711
ID: 24308604
Yes you are right,

cutting out the data from the file itself could help. I can delete the tags in XML spy right?
0
DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

 
LVL 60

Assisted Solution

by:Geert Bormans
Geert Bormans earned 500 total points
ID: 24308641
you can, allthough 160MB is a bit hard for SPY to edit...
you can try, if it kills Spy, use a text editor for large files
0
 
LVL 60

Expert Comment

by:Geert Bormans
ID: 24308649
160MB files very often are dumps from a database, If you have two rows instead of a million rows, you would still generate the same schema
0
 
LVL 10

Author Comment

by:aman0711
ID: 24308811
Yeah, tried to open it with Spy.. till now working file.

I trimmed lot of lines till now..
0
 
LVL 10

Author Closing Comment

by:aman0711
ID: 31578189
Thanks :)
0
 
LVL 60

Expert Comment

by:Geert Bormans
ID: 24339077
welcome
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction In my previous article (http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/SSIS/A_9150-Loading-XML-Using-SSIS.html) I showed you how the XML Source component can be used to load XML files into a SQL Server database, us…
Browsing the questions asked to the Experts of this forum, you will be amazed to see how many times people are headaching about monster regular expressions (regex) to select that specific part of some HTML or XML file they want to extract. The examp…
This is a video describing the growing solar energy use in Utah. This is a topic that greatly interests me and so I decided to produce a video about it.
This is a video that shows how the OnPage alerts system integrates into ConnectWise, how a trigger is set, how a page is sent via the trigger, and how the SENT, DELIVERED, READ & REPLIED receipts get entered into the internal tab of the ConnectWise …

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now