String hql = "select new net.shopnc.b2b2c.vo.goods.GoodsVo(gc, sum(g.goodsStorage)) from GoodsCommon gc, Goods g where gc.goodsId = g.id";
sql语句中把查询到的对象封装到另一个对象中
最新推荐文章于 2022-04-28 22:42:04 发布

String hql = "select new net.shopnc.b2b2c.vo.goods.GoodsVo(gc, sum(g.goodsStorage)) from GoodsCommon gc, Goods g where gc.goodsId = g.id";