java.lang.NumberFormaException: For input String:"user"
碰到这个问题的时候有点懵逼,很无力,网上一查是类型转换错误,贴上报错的JSP代码
最后找救兵,得出是hql的错误,举个例子:
HibernateUtil.query("from user u,info i");
最终查询出来的结果是一张集合表,前台是get不到关联表的数据的,得这样写
HibernateUtil.query("select u from user u,info i");
解决了!
java.lang.NumberFormaException: For input String:"user"的更多相关文章
- java.lang.NumberFormatException: For input string: "1608020001 " 错误
错误: java.lang.NumberFormatException: For input string: "1608020001 " at java.lang.Numbe ...
- java.lang.NumberFormatException: For input string: "Y"
nested exception is org.apache.ibatis.exceptions.PersistenceException: ### Error querying database. ...
- mybatis 报错:Caused by: java.lang.NumberFormatException: For input string
mybatis的if标签之前总是使用是否为空,今天要用到字符串比较的时候遇到了困难,倒腾半天,才在一个论坛上找到解决方法.笔记一下,如下: 转自:https://code.google.com/p/m ...
- java.lang.NumberFormatException: For input string:"filesId"
做项目时候,页面获取出现了这个问题.找了好久一直以为是我字段或者是数据库字段问题导致引起的. 最后才发现是 struts2中jsp我写错了一个参数,一直导致报错.后来改了就好了. 当大家遇到这个问题的 ...
- 解决java.lang.NumberFormatException: For input string: "id"
今天,项目突然报"java.lang.NumberFormatException:For input string:"id"",项目框架是spring,spri ...
- MyBatis报错:Caused by: java.lang.NumberFormatException: For input string: "XX"
<select id="sltTreatment" resultType="com.vitaminmd.sunny.core.bo.Treatment"& ...
- Caused by: java.lang.NumberFormatException: For input string: "18446744073709551615"
问题:Caused by: java.lang.NumberFormatException: For input string: "18446744073709551615" 原因 ...
- Redis集群环境使用的是redis4.0.x的版本,在用java客户端jedisCluster启动集群做数据处理时报java.lang.NumberFormatException: For input string: "7003@17003"问题解决
java.lang.NumberFormatException: For input string: "7003@17003" at java.lang.NumberFormatE ...
- hadoop ha环境下的datanode启动报错java.lang.NumberFormatException: For input string: "10m"
hadoop ha环境启动start-dfs.sh的时候datanode启动不了,并且报错. [hadoop@datanode2 ~]$ cat /home/hadoop/hadoop-2.7.3/l ...
随机推荐
- Dataframe 多行合并为一行
原表数据: 最后4行合并为1行: def ab(df): return','.join(df.values) df = df.groupby(['股票代码','股票简称'])['所属概念'].appl ...
- markdown code test - markdown code test - markdown code test - markdown code test
目录 主要代码 bottom cc 主要代码 <div class="tocCol1 js-toc"></div> <a>bc</a> ...
- class的真相
Java中Class类及用法 Java程序在运行时,Java运行时系统一直对所有的对象进行所谓的运行时类型标识,即所谓的RTTI.这项信息纪录了每个对象所属的类.虚拟机通常使用运行时类型信息选准正确方 ...
- xpath解析数据
xpath解析数据 """ xpath 也是一种用于解析xml文档数据的方式 xml path w3c xpath搜索用法 在 XPath 中,有七种类型的节点:元素.属 ...
- Servlet CDI example analysis
上下文和依赖注入(CDI)使您的对象能够自动为它们提供依赖项,而不是创建它们或将它们作为参数接收.CDI还为您管理这些依赖项的生命周期. 例如,考虑以下servlet: @WebServlet(&qu ...
- hdfs性能调优(cloudera)
参照官方文档:http://www.cloudera.com/content/cloudera/en/documentation/core/latest/topics/cdh_ig_yarn_tuni ...
- Best Practices for Assembly Loading
原文链接 This article discusses ways to avoid problems of type identity that can lead to InvalidCastExce ...
- C C++互相调用注意
注意:直接调用会找不到函数定义 1. C 调用 C++封装好后的函数: 在C++中有一个函数 int main_cpp(): 首先构建头文件, #ifndef CPP_FILE_H #define ...
- CSRF、XSS、clickjacking、SQL 的攻击与防御
CSRF攻击 原理: 跨站请求伪造.是一种挟制用户在当前已登录的Web应用程序上执行非本意的操作的攻击方法. 网站通过cookie来实现登录功能.而cookie只要存在浏览器中,那么浏览器在访问含有这 ...
- Hadoop入门
一.Hadoop是什么 1)Hadoop是一个由Apache基金会所开发的分布式系统基础架构. 2)Hadoop主要解决,海量数据的存储和海量数据的分析计算问题. 3)广义上来说,Hadoop通常是指 ...