in reply to Parse XML of large size

You could look at using XML::Twig, which bills itself as being able to process huge XML files. Alternativly you could profile your code with Devel::NYTProf to see if there are any points for improvement, see also Debugging and Optimization from the tutorials section of this site. This of course would require you to change some of your code, however since you don't show us your code we can't point out any issues it may have, or suggest areas for improvement.

Replies are listed 'Best First'.
Re^2: Parse XML of large size
by kalyanrajsista (Scribe) on Dec 01, 2009 at 12:07 UTC

    Here is the pretty simple code.

    I've dumped XML file into Perl's data structure using XMLin() which itself is taking so much of time.

    Rest of the other processing to extract the data is not taking much time for me..

    use strict; use warnings; use XML::Simple; use XML::LibXML; my $XML_FILE = 'sample.xml'; # Dump of the XML file in Perl's Data Structures my $mldata = XMLin($XML_FILE);

        Why my replies and others replies are not visible for me. I'm confused....

      A reply falls below the community's threshold of quality. You may see it by logging in.

      BTW, use XML::LibXML is superfluous here, as you're not actually using it anywhere in the code...

        I'm sorry for that. I'm using XML::LibXML to validate my XML against the XSD. I've removed the code while posting.