java.sql.SQLException

Must declare the scalar variable "@P0".

Samebug tips0

We couldn't find tips for this exception.

Don't give up yet. Paste your full stack trace to get a solution.

Solutions on the web443

Stack trace

  • java.sql.SQLException: Must declare the scalar variable "@P0". at net.sourceforge.jtds.jdbc.SQLDiagnostic.addDiagnostic(SQLDiagnostic.java:372) at net.sourceforge.jtds.jdbc.TdsCore.tdsErrorToken(TdsCore.java:2988) at net.sourceforge.jtds.jdbc.TdsCore.nextToken(TdsCore.java:2421) at net.sourceforge.jtds.jdbc.TdsCore.getMoreResults(TdsCore.java:671) at net.sourceforge.jtds.jdbc.MSCursorResultSet.processOutput(MSCursorResultSet.java:943) at net.sourceforge.jtds.jdbc.MSCursorResultSet.cursorCreate(MSCursorResultSet.java:541) at net.sourceforge.jtds.jdbc.MSCursorResultSet.<init>(MSCursorResultSet.java:154) at net.sourceforge.jtds.jdbc.JtdsStatement.executeSQL(JtdsStatement.java:549) at net.sourceforge.jtds.jdbc.JtdsPreparedStatement.execute(JtdsPreparedStatement.java:787)

Write tip

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

Users with the same issue

oddodd
4 times, last one
Unknown visitor
Unknown visitorOnce,
Unknown visitor
Unknown visitorOnce,
EricEric
3 times, last one
Unknown visitor
Unknown visitorOnce,
22 more bugmates