String sql="select new com.gehua.InfoSystem.pojo.CPayRecord_CFix(cp.id,cp.yhId,cp.beizhu,cp.PTimestamp,cp.PZhuantai,cp.macaddress,cp.churen,cp.chushi,cf.azCmMac) from CPayRecord as cp ,CFix as cf where cp.yhId=cf.yhId";
??类CPayRecord_CFix
public class CPayRecord_CFix { private Integer id;
private String yhId;
private String beizhu;
private Date PTimestamp;
private String PZhuantai;
private String macaddress;
private String churen;
private String chushi;
private String azCmMac;
public CPayRecord_CFix(){
} public CPayRecord_CFix(
Integer id,
String yhId, String beizhu,
Date PTimestamp,String PZhuantai,
String macaddress, String churen,
String chushi
, String azCmMac
) {
this.id = id;
this.yhId = yhId;
this.beizhu = beizhu;
this.PTimestamp = PTimestamp;
this.PZhuantai = PZhuantai;
this.macaddress = macaddress;
this.churen = churen;
this.chushi = chushi;
this.azCmMac = azCmMac;
}
...get(),set()方法...
为何老是报
Cause:
org.hibernate.PropertyNotFoundException: no appropriate constructor in class: com.gehua.InfoSystem.pojo.CPayRecord_CFix
解决方案 »
- 我是一启动MySQL Command Line Client,就直接进入root用户了……,怎么样才能退出root用户和怎么切换我的管理员账户呢?
- 财务软件接口 高手帮忙
- 有关ActiveX控件的问题~~~~~~请教高手
- 求教一段session验证登录代码
- strutsl里配置数据源的问题
- applet的问题,高人指点!!!HttpURLConnection的disconect方法调用无效~~~~~~~~~~~~~~~
- 一个弱弱的问题:该如何设置才能用JAVAX包
- 功能最全的登陆页面怎么实现?
- 【高分200】如何分析这个xml,得到所有节点,用于创建数据表,生成类
- 一个小问题
- oracle 连接问题
- 两个小问题
你有这个CPayRecord 类吗?
select new com.gehua.InfoSystem.pojo.CPayRecord_CFix(cp.id,cp.yhId,cp.beizhu,cp.PTimestamp,cp.PZhuantai,cp.macaddress,cp.churen,cp.chushi,cf.azCmMac) from CPayRecord as cp ,CFix as cf where cp.yhId=cf.yhId";
这里的参数顺序和构造函数的参数顺序是一样的啊,但是我测试了一下只查一个表的时候就不报错