Good Morning Larry-

the stack gets as far as
org.springframework.orm.ibatis.SqlMapClientTemplate.execute(SqlMapClientTemplate.java:171)

/************here is the SqlMapClientTenplate.java**********************/
 public Object execute(SqlMapClientCallback action) throws DataAccessException {
  Assert.notNull(this.sqlMapClient, "No SqlMapClient specified");
  // We always needs to use a SqlMapSession, as we need to pass a Spring-managed
  // Connection (potentially transactional) in. This shouldn't be necessary if
  // we run against a TransactionAwareDataSourceProxy underneath, but 
unfortunately
  // we still need it to make iBATIS batch execution work properly: If iBATIS
  // doesn't recognize an existing transaction, it automatically executes the
  // batch for every single statement...

  SqlMapSession session = this.sqlMapClient.openSession(); //ok!
  try {
   Connection con = DataSourceUtils.getConnection(getDataSource()); //ok!
   try {
    session.setUserConnection(con); //OK!
    return action.doInSqlMapClient(session); //woops!
   }
   catch (SQLException ex) {
    throw getExceptionTranslator().translate("SqlMapClient operation", null, 
ex);
   }

/****meanwhile in SqlMapClientCallback.java there is the declaration for method 
doInSqlMapClient within SqlMapClientCallback.java***/
Object doInSqlMapClient(com.ibatis.sqlmap.client.SqlMapExecutor executor) 
throws SQLException;

/******* not much can go wrong here except of course if the SqlMapExecutor 
object is not properly constructed **********/
/******I'll try to ping the ibatis folks as there is an error with the 
construction of the SqlMapExecutor and look at that constructor***/

Ideas?
M-

This e-mail communication and any attachments may contain confidential and 
privileged information for the use of the 
designated recipients named above. If you are not the intended recipient, you 
are hereby notified that you have received
this communication in error and that any review, disclosure, dissemination, 
distribution or copying of it or its 
contents
----- Original Message ----- 
From: "Larry Meadors" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <user@struts.apache.org>; "Martin Gainty" 
<[EMAIL PROTECTED]>
Sent: Saturday, October 28, 2006 10:46 PM
Subject: Re: spring jpetstore demo error (possibly O/T)


> Not sure if there is a typo in your email or if your copy of the
> Category.xml file somehow got buggered up, but there is a trailing "."
> on the select statement there. That would make it puke, but like I
> said, I am not positive that that is the real problem, or just a weird
> typo. Can you check it and let use know?
> 
> Larry
> 
> 
> On 10/28/06, Martin Gainty <[EMAIL PROTECTED]> wrote:
>> Has anyone encountered this error with the spring jpetstore sample and know 
>> the solution?org.springframework.web.util.NestedServletException: Request 
>> processing failed; nested exception is 
>> org.springframework.jdbc.BadSqlGrammarException: SqlMapClient operation; bad 
>> SQL grammar []; nested exception is 
>> com.ibatis.common.jdbc.exception.NestedSQLException:
>> --- The error occurred in 
>> org/springframework/samples/jpetstore/dao/ibatis/maps/Category.xml.
>> --- The error occurred while executing query.
>> --- Check the      select catid,name,descn from category where catid = 'dog' 
>>    .
>> --- Check the SQL Statement (preparation failed).
>> Many Thanks,Martin --This e-mail communication and any attachments may 
>> contain confidential and privileged information for the use of the
>> designated recipients named above. If you are not the intended recipient, 
>> you are hereby notified that you have received
>> this communication in error and that any review, disclosure, dissemination, 
>> distribution or copying of it or its
>> contents
>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
>

Reply via email to