我在java中调用sqlServer的存储过程
cstmt=getconn().prepareCall("{call pro_test(?,?,?)}");
cstmt.setString(1,t1);
cstmt.setInt(2,t2);
cstmt.setInt(3,t3);
当t1.length>254就抛异常,小于254的时候没事
java.sql.SQLException: [Microsoft][ODBC SQL Server Driver][SQL Server]不
允许从数据类型 text 到 nvarchar 的隐性转换。请使用 CONVERT 函数来运行此查询。
------------------------
我在存储中的对应设置是@t1 nvarchar(1000)
而且在sql查询器运行OK
---------------------------
怎么办??