java.sql.SQLException: Could not set parameter at position 3, parameter length is 2

GitHub | cristianspinetta | 8 months ago
tip
Do you know that we can give you better hits? Get more relevant results from Samebug’s stack trace search.
  1. 0

    SQL interpolation with PointFromText('POINT(?, ?)') function in MariaDB

    GitHub | 8 months ago | cristianspinetta
    java.sql.SQLException: Could not set parameter at position 3, parameter length is 2
  2. 0

    Jackson unable to process JSON

    GitHub | 10 months ago | tmcdevitt85
    java.sql.SQLException: Could not set parameter at position 4, parameter length is 3

    Root Cause Analysis

    1. java.sql.SQLException

      Could not set parameter at position 3, parameter length is 2

      at org.mariadb.jdbc.internal.util.ExceptionMapper.getSqlException()
    2. org.mariadb.jdbc
      ExceptionMapper.getSqlException
      1. org.mariadb.jdbc.internal.util.ExceptionMapper.getSqlException(ExceptionMapper.java:149)
      1 frame
    3. mariadb-java-client
      AbstractMariaDbPrepareStatement.setDouble
      1. org.mariadb.jdbc.MariaDbServerPreparedStatement.setParameter(MariaDbServerPreparedStatement.java:151)
      2. org.mariadb.jdbc.AbstractMariaDbPrepareStatement.setDouble(AbstractMariaDbPrepareStatement.java:1322)
      2 frames
    4. Commons DBCP
      DelegatingPreparedStatement.setDouble
      1. org.apache.commons.dbcp.DelegatingPreparedStatement.setDouble(DelegatingPreparedStatement.java:129)
      2. org.apache.commons.dbcp.DelegatingPreparedStatement.setDouble(DelegatingPreparedStatement.java:129)
      2 frames
    5. scalikejdbc-core
      StatementExecutor$$anonfun$bindParams$2.apply
      1. scalikejdbc.StatementExecutor.scalikejdbc$StatementExecutor$$bind(StatementExecutor.scala:88)
      2. scalikejdbc.StatementExecutor$$anonfun$bindParams$2.apply(StatementExecutor.scala:67)
      3. scalikejdbc.StatementExecutor$$anonfun$bindParams$2.apply(StatementExecutor.scala:66)
      3 frames
    6. Scala
      TraversableLike$WithFilter.foreach
      1. scala.collection.TraversableLike$WithFilter$$anonfun$foreach$1.apply(TraversableLike.scala:733)
      2. scala.collection.immutable.List.foreach(List.scala:381)
      3. scala.collection.TraversableLike$WithFilter.foreach(TraversableLike.scala:732)
      3 frames
    7. scalikejdbc-core
      SQLUpdateWithGeneratedKey.apply
      1. scalikejdbc.StatementExecutor.bindParams(StatementExecutor.scala:66)
      2. scalikejdbc.StatementExecutor.initialize(StatementExecutor.scala:50)
      3. scalikejdbc.StatementExecutor.<init>(StatementExecutor.scala:44)
      4. scalikejdbc.DBSession$class.createStatementExecutor(DBSession.scala:103)
      5. scalikejdbc.DBSession$class.updateWithFilters(DBSession.scala:469)
      6. scalikejdbc.ActiveSession.updateWithFilters(DBSession.scala:706)
      7. scalikejdbc.DBSession$class.updateAndReturnSpecifiedGeneratedKey(DBSession.scala:564)
      8. scalikejdbc.ActiveSession.updateAndReturnSpecifiedGeneratedKey(DBSession.scala:706)
      9. scalikejdbc.SQLUpdateWithGeneratedKey$$anonfun$10.apply(SQL.scala:646)
      10. scalikejdbc.SQLUpdateWithGeneratedKey$$anonfun$10.apply(SQL.scala:646)
      11. scalikejdbc.DBConnection$$anonfun$autoCommit$1.apply(DBConnection.scala:221)
      12. scalikejdbc.DBConnection$$anonfun$autoCommit$1.apply(DBConnection.scala:221)
      13. scalikejdbc.LoanPattern$class.using(LoanPattern.scala:18)
      14. scalikejdbc.NamedDB.using(NamedDB.scala:17)
      15. scalikejdbc.DBConnection$class.autoCommit(DBConnection.scala:221)
      16. scalikejdbc.NamedDB.autoCommit(NamedDB.scala:17)
      17. scalikejdbc.SQLUpdateWithGeneratedKey.apply(SQL.scala:650)
      17 frames
    8. playground.model
      GeoNodeRepository$.create
      1. playground.model.GeoNodeRepository$.create(GeoNode.scala:54)
      1 frame
    9. playground
      DBTest$$anonfun$3.apply
      1. playground.DBTest$$anonfun$3.apply(DBTest.scala:28)
      2. playground.DBTest$$anonfun$3.apply(DBTest.scala:27)
      2 frames