iBATIS 2.0 is backward compatible with 1.0 -- but 2.0 is highly recommended. You had a spelling error when you requested your statement, for which it did complain loudly with "There is no statement named..."
Cheers, Clinton On Thu, 17 Feb 2005 11:09:03 -0700, Baker, Russ <[EMAIL PROTECTED]> wrote: > Thanks Clinton, > > This kinda raises an interesting issue though. I had no problem parsing the > sql-map-config.xml file, and when I buggered that up, the app complained. > However, if the sql map xml files are buggered up, then it doesn't complain > but just says it cannot find the statement. So if it cannot parse the xml > file, is there a way to have it complain loudly that there is a problem? > > Thanks, > > Russ > > -----Original Message----- > From: Clinton Begin [mailto:[EMAIL PROTECTED] > Sent: Thursday, February 17, 2005 11:01 AM > To: [email protected] > Subject: Re: Cannot get sqlMaq > > Yeah, the XML files are quite messed up. You're using a combination > of 1.0 and 2.0 ....perhaps the problem you're having all around. > > I'd suggest you re-download everything all over again. Start over > with the 2.0 tutorial and JPetStore 4 as an example. > > Also check out the articles posted on the homepage. > > Cheers, > Clinton > > On Thu, 17 Feb 2005 10:50:04 -0700, Baker, Russ <[EMAIL PROTECTED]> wrote: > > Kris, > > > > Thanks for the info. I looked at the "statement" spelling and corrected > > that. What exactly do you mean by v2, the xml version? > > > > Thanks, > > > > Russ > > > > -----Original Message----- > > From: Kris Jenkins [mailto:[EMAIL PROTECTED] > > Sent: Thursday, February 17, 2005 10:46 AM > > To: [email protected] > > Subject: Re: Cannot get sqlMaq > > > > In addition, it looks like you're using v1. I'd strongly advise you to > > upgrade to v2 if you're just getting started. > > > > Kris > > > > roberto wrote: > > > > ><statement> is misspelled in EnergencyContact.xml. > > > > > >Roberto > > > > > > > > > > > > > > >>-----Original Message----- > > >>From: Baker, Russ [mailto:[EMAIL PROTECTED] > > >>Sent: Thursday, February 17, 2005 12:28 PM > > >>To: [email protected] > > >>Subject: Cannot get sqlMaq > > >> > > >>Hello, > > >> > > >>I am having issues with creating a sql map. I have set up the application > > >>according to the developer's guide, and for some reason, it isn't loading > > >>the sql maps. I have enclosed the configuration files and the Java file > > >>that gets the sqlMap. I have isolated the handing out of the SqlMapClient > > >>via a singleton, and for testing purposes, I used the SqlMapClientImpl so > > >>I can get at the SqlMapExecutorDelegate to see what SqlMaps are loaded. I > > >>wrote a test for the singleton and am getting the following stack trace: > > >> > > >>com.ibatis.sqlmap.client.SqlMapException: There is no statement named > > >>getEmergencyInfo in this SqlMap. > > >> at > > >>com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.getMappedStatement(Sq > > >>lMapExecutorDelegate.java:288) > > >> at > > >>com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForObject(SqlMap > > >>ExecutorDelegate.java:552) > > >> at > > >>com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.queryForObject(SqlMap > > >>ExecutorDelegate.java:536) > > >> at > > >>com.ibatis.sqlmap.engine.impl.SqlMapSessionImpl.queryForObject(SqlMapSessi > > >>onImpl.java:97) > > >> at > > >>com.ibatis.sqlmap.engine.impl.SqlMapClientImpl.queryForObject(SqlMapClient > > >>Impl.java:69) > > >> at > > >>com.ball.persistence.ibatis.dao.IbatisSqlMapManagerTest.testBTestSqlMap(Ib > > >>atisSqlMapManagerTest.java:38) > > >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > > >> at > > >>sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java: > > >>39) > > >> at > > >>sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorIm > > >>pl.java:25) > > >> at java.lang.reflect.Method.invoke(Method.java:324) > > >> at junit.framework.TestCase.runTest(TestCase.java:154) > > >> at junit.framework.TestCase.runBare(TestCase.java:127) > > >> at junit.framework.TestResult$1.protect(TestResult.java:106) > > >> at junit.framework.TestResult.runProtected(TestResult.java:124) > > >> at junit.framework.TestResult.run(TestResult.java:109) > > >> at junit.framework.TestCase.run(TestCase.java:118) > > >> at junit.framework.TestSuite.runTest(TestSuite.java:208) > > >> at junit.framework.TestSuite.run(TestSuite.java:203) > > >> at junit.textui.TestRunner.doRun(TestRunner.java:116) > > >> at > > >>com.intellij.rt.execution.junit2.IdeaJUnitAgent.doRun(IdeaJUnitAgent.java: > > >>57) > > >> at junit.textui.TestRunner.start(TestRunner.java:172) > > >> at > > >>com.intellij.rt.execution.junit.TextTestRunner2.startRunnerWithArgs(TextTe > > >>stRunner2.java:23) > > >> at > > >>com.intellij.rt.execution.junit2.JUnitStarter.prepareStreamsAndStart(JUnit > > >>Starter.java:97) > > >> at > > >>com.intellij.rt.execution.junit2.JUnitStarter.main(JUnitStarter.java:31) > > >> > > >>What could be possibly happening? I thought that I set up the files the > > >>way the Developer's Guide states. > > >> > > >> > > >>Thanks, > > >> > > >>Russ B. > > >> > > >> > > > > > > > > > > > > > > > > > > > -- > > Kris Jenkins > > Email: [EMAIL PROTECTED] > > Blog: http://cafe.jenkster.com/ > > Wiki: http://wiki.jenkster.com/ > > > > >

