StringBuilder sqlQry = new StringBuilder();
sqlQry.append("SELECT LIB, PATH")
.append(" FROM OBJ")
.append(" INNER JOIN SRC ON SRC.MBR = OBJ.LOBJ")
.append(" WHERE TYPE = '*PGM'")
.append(" AND SRC.PATH LIKE '").append("?").append("%'");
PreparedStatement ps = accssConn.prepareStatement(sqlQry.toString());
ps.setString(1, path);
rs = ps.executeQuery();
大家好,我收到以下异常
[jcc][10145][10844][3.63.123] Invalid parameter 1: Parameter index is out of range. ERRORCODE=-4461, SQLSTATE=42815
列限制为 255,路径为 = "C:\Documents and Settings\xyz\Desktop\xyzs" 并且在语句中运行良好。那么,它在准备好的语句中抛出异常的原因是什么。