0 Replies Latest reply on Feb 1, 2003 9:30 AM by Oleg Lioubtchenko

    Help! EJB-QL to SQL mapping error.

    Oleg Lioubtchenko Newbie

      Simple example from ejb-jar.xml, like:
      FROM InDataBean o
      WHERE o.pinSn = '?1'

      Produce an error:

      javax.ejb.FinderException: Find failed: java.sql.SQLException: Syntax error or a
      ccess violation:

      You have an error in your SQL syntax near 'FROM INDATA t0_o WHERE t0_o.pinSn = '51009334'' at line 1

      at org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractQueryCommand.execute(JDBCA

      I suppose that word "AS" was not translated to SQL.
      If it were:

      FROM INDATA AS t0_o WHERE t0_o.pinSn = '51009334'

      May be it would be better?
      (PS: pinSn is a String.)