Jump to content
Changes to the Jaspersoft community edition download ×

Help me solving this error! Thank you


Recommended Posts

By: Xuan Hao - xuanhao

Help me solving this error! Thank you

2002-09-03 02:52

When compiling my first XML report file, I received errors:

Parse Error at line -1 column -1: Document root element "jasperReport", must mat

ch DOCTYPE root "null".

org.xml.sax.SAXParseException: Document root element "jasperReport", must match

DOCTYPE root "null".

at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Er

rorHandlerWrapper.java:223)

at org.apache.xerces.util.ErrorHandlerWrapper.error(ErrorHandlerWrapper.

java:170)

at org.apache.xerces.impl.XMLErrorReporter.reportError(XMLErrorReporter.

java:363)

at org.apache.xerces.impl.XMLErrorReporter.reportError(XMLErrorReporter.

java:297)

at org.apache.xerces.impl.dtd.XMLDTDValidator.rootElementSpecified(XMLDT

DValidator.java:2286)

at org.apache.xerces.impl.dtd.XMLDTDValidator.handleStartElement(XMLDTDV

alidator.java:2594)

at org.apache.xerces.impl.dtd.XMLDTDValidator.startElement(XMLDTDValidat

or.java:782)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElemen

t(XMLDocumentFragmentScannerImpl.java:747)

at org.apache.xerces.impl.XMLDocumentScannerImpl$ContentDispatcher.scanR

ootElementHook(XMLDocumentScannerImpl.java:930)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContent

Dispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1510)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XM

LDocumentFragmentScannerImpl.java:328)

at org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardP

arserConfiguration.java:479)

at org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardP

arserConfiguration.java:521)

at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:148)

at org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.j

ava:972)

at org.apache.commons.digester.Digester.parse(Digester.java:1206)

at dori.jasper.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:498)

at dori.jasper.engine.xml.JRXmlLoader.load(JRXmlLoader.java:286)

at dori.jasper.engine.JasperCompileManager.compileReportToFile(JasperCom

pileManager.java:49)

at dori.jasper.engine.JasperManager.compileReportToFile(JasperManager.ja

va:845)

at DataSourceReport.main(DataSourceReport.java:49)

Parse Error at line -1 column -1: Document is invalid: no grammar found.

org.xml.sax.SAXParseException: Document is invalid: no grammar found.

at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Er

rorHandlerWrapper.java:223)

at org.apache.xerces.util.ErrorHandlerWrapper.error(ErrorHandlerWrapper.

java:170)

at org.apache.xerces.impl.XMLErrorReporter.reportError(XMLErrorReporter.

java:363)

at org.apache.xerces.impl.XMLErrorReporter.reportError(XMLErrorReporter.

java:297)

at org.apache.xerces.impl.dtd.XMLDTDValidator.handleStartElement(XMLDTDV

alidator.java:2606)

at org.apache.xerces.impl.dtd.XMLDTDValidator.startElement(XMLDTDValidat

or.java:782)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElemen

t(XMLDocumentFragmentScannerImpl.java:747)

at org.apache.xerces.impl.XMLDocumentScannerImpl$ContentDispatcher.scanR

ootElementHook(XMLDocumentScannerImpl.java:930)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContent

Dispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1510)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XM

LDocumentFragmentScannerImpl.java:328)

at org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardP

arserConfiguration.java:479)

at org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardP

arserConfiguration.java:521)

at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:148)

at org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.j

ava:972)

at org.apache.commons.digester.Digester.parse(Digester.java:1206)

at dori.jasper.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:498)

at dori.jasper.engine.xml.JRXmlLoader.load(JRXmlLoader.java:286)

at dori.jasper.engine.JasperCompileManager.compileReportToFile(JasperCom

pileManager.java:49)

at dori.jasper.engine.JasperManager.compileReportToFile(JasperManager.ja

va:845)

at DataSourceReport.main(DataSourceReport.java:49)

Begin event threw exception

java.lang.NumberFormatException: null

at java.lang.Integer.parseInt(Integer.java:394)

at java.lang.Integer.parseInt(Integer.java:476)

at dori.jasper.engine.xml.JasperDesignFactory.createObject(JasperDesignF

actory.java:51)

at org.apache.commons.digester.FactoryCreateRule.begin(FactoryCreateRule

.java:172)

at org.apache.commons.digester.Digester.startElement(Digester.java:939)

at org.apache.xerces.parsers.AbstractSAXParser.startElement(AbstractSAXP

arser.java:342)

at org.apache.xerces.impl.xs.XMLSchemaValidator.startElement(XMLSchemaVa

lidator.java:401)

at org.apache.xerces.impl.XMLNamespaceBinder.handleStartElement(XMLNames

paceBinder.java:809)

at org.apache.xerces.impl.XMLNamespaceBinder.startElement(XMLNamespaceBi

nder.java:556)

at org.apache.xerces.impl.dtd.XMLDTDValidator.handleStartElement(XMLDTDV

alidator.java:2678)

at org.apache.xerces.impl.dtd.XMLDTDValidator.startElement(XMLDTDValidat

or.java:782)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElemen

t(XMLDocumentFragmentScannerImpl.java:747)

at org.apache.xerces.impl.XMLDocumentScannerImpl$ContentDispatcher.scanR

ootElementHook(XMLDocumentScannerImpl.java:930)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContent

Dispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1510)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XM

LDocumentFragmentScannerImpl.java:328)

at org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardP

arserConfiguration.java:479)

at org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardP

arserConfiguration.java:521)

at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:148)

at org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.j

ava:972)

at org.apache.commons.digester.Digester.parse(Digester.java:1206)

at dori.jasper.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:498)

at dori.jasper.engine.xml.JRXmlLoader.load(JRXmlLoader.java:286)

at dori.jasper.engine.JasperCompileManager.compileReportToFile(JasperCom

pileManager.java:49)

at dori.jasper.engine.JasperManager.compileReportToFile(JasperManager.ja

va:845)

at DataSourceReport.main(DataSourceReport.java:49)

nulljava.lang.NumberFormatException: null

at org.apache.commons.digester.Digester.createSAXException(Digester.java

:1763)

at org.apache.commons.digester.Digester.createSAXException(Digester.java

:1785)

at org.apache.commons.digester.Digester.startElement(Digester.java:942)

at org.apache.xerces.parsers.AbstractSAXParser.startElement(AbstractSAXP

arser.java:342)

at org.apache.xerces.impl.xs.XMLSchemaValidator.startElement(XMLSchemaVa

lidator.java:401)

at org.apache.xerces.impl.XMLNamespaceBinder.handleStartElement(XMLNames

paceBinder.java:809)

at org.apache.xerces.impl.XMLNamespaceBinder.startElement(XMLNamespaceBi

nder.java:556)

at org.apache.xerces.impl.dtd.XMLDTDValidator.handleStartElement(XMLDTDV

alidator.java:2678)

at org.apache.xerces.impl.dtd.XMLDTDValidator.startElement(XMLDTDValidat

or.java:782)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElemen

t(XMLDocumentFragmentScannerImpl.java:747)

at org.apache.xerces.impl.XMLDocumentScannerImpl$ContentDispatcher.scanR

ootElementHook(XMLDocumentScannerImpl.java:930)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContent

Dispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1510)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XM

LDocumentFragmentScannerImpl.java:328)

at org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardP

arserConfiguration.java:479)

at org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardP

arserConfiguration.java:521)

at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:148)

at org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.j

ava:972)

at org.apache.commons.digester.Digester.parse(Digester.java:1206)

at dori.jasper.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:498)

at dori.jasper.engine.xml.JRXmlLoader.load(JRXmlLoader.java:286)

at dori.jasper.engine.JasperCompileManager.compileReportToFile(JasperCom

pileManager.java:49)

at dori.jasper.engine.JasperManager.compileReportToFile(JasperManager.ja

va:845)

at DataSourceReport.main(DataSourceReport.java:49)

 

NESTED BY :

java.lang.NumberFormatException: null

at org.apache.commons.digester.Digester.createSAXException(Digester.java

:1763)

at org.apache.commons.digester.Digester.createSAXException(Digester.java

:1785)

at org.apache.commons.digester.Digester.startElement(Digester.java:942)

at org.apache.xerces.parsers.AbstractSAXParser.startElement(AbstractSAXP

arser.java:342)

at org.apache.xerces.impl.xs.XMLSchemaValidator.startElement(XMLSchemaVa

lidator.java:401)

at org.apache.xerces.impl.XMLNamespaceBinder.handleStartElement(XMLNames

paceBinder.java:809)

at org.apache.xerces.impl.XMLNamespaceBinder.startElement(XMLNamespaceBi

nder.java:556)

at org.apache.xerces.impl.dtd.XMLDTDValidator.handleStartElement(XMLDTDV

alidator.java:2678)

at org.apache.xerces.impl.dtd.XMLDTDValidator.startElement(XMLDTDValidat

or.java:782)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElemen

t(XMLDocumentFragmentScannerImpl.java:747)

at org.apache.xerces.impl.XMLDocumentScannerImpl$ContentDispatcher.scanR

ootElementHook(XMLDocumentScannerImpl.java:930)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContent

Dispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1510)

at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XM

LDocumentFragmentScannerImpl.java:328)

at org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardP

arserConfiguration.java:479)

at org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardP

arserConfiguration.java:521)

at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:148)

at org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.j

ava:972)

at org.apache.commons.digester.Digester.parse(Digester.java:1206)

at dori.jasper.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:498)

at dori.jasper.engine.xml.JRXmlLoader.load(JRXmlLoader.java:286)

at dori.jasper.engine.JasperCompileManager.compileReportToFile(JasperCom

pileManager.java:49)

at dori.jasper.engine.JasperManager.compileReportToFile(JasperManager.ja

va:845)

at DataSourceReport.main(DataSourceReport.java:49)

 

NESTED BY :

dori.jasper.engine.JRException: Error at (-1, -1: null

at dori.jasper.engine.xml.JRXmlLoader.loadXML(JRXmlLoader.java:502)

at dori.jasper.engine.xml.JRXmlLoader.load(JRXmlLoader.java:286)

at dori.jasper.engine.JasperCompileManager.compileReportToFile(JasperCom

pileManager.java:49)

at dori.jasper.engine.JasperManager.compileReportToFile(JasperManager.ja

va:845)

at DataSourceReport.main(DataSourceReport.java:49)

Please help me! Thank you in advanced!

 

 

By: Teodor Danciu - teodord

RE: Help me solving this error! Thank you

2002-09-03 04:38

 

Hi,

 

You don't have a reference to the DTD file

in your XML report design.

See the <!DOCTYPE> element in the samples.

 

It seems that it is missing from your file.

 

Good luck!

Teodor

Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...