首页 > 数据库技术 > 详细

java.sql.SQLSyntaxErrorException: ORA-00923: 未找到要求的 FROM 关键字

时间:2019-07-17 11:50:42      阅读:381      评论:0      收藏:0      [点我收藏+]

NFO:HibernateSimpleDao----queryForListWithSql:SELECT site_id as id ,
MAX(case attr_name when ‘siteName‘ then attr_value END) as ‘siteName‘,
MAX(case attr_name when ‘userName‘ then attr_value END) as ‘userName‘,
MAX(case attr_name when ‘password‘ then attr_value END) as ‘password‘,
MAX(case attr_name when ‘tjSiteId‘ then attr_value END) as ‘tjSiteId‘,
MAX(case attr_name when ‘tjToken‘ then attr_value END) as ‘tjToken‘
FROM jc_site_attr where attr_name in (‘siteName‘,‘userName‘,‘password‘,‘tjToken‘,‘tjSiteId‘) GROUP BY site_id ORDER BY site_id
2019-07-17 10:53:02 上午 [Thread: http-8080-1][ Class:com.mchange.v2.c3p0.impl.NewPooledConnection Method: com.mchange.v2.log.slf4j.Slf4jMLog$Slf4jMLogger$DebugLogger.log(Slf4jMLog.java:207) ]
DEBUG:com.mchange.v2.c3p0.impl.NewPooledConnection@2f9923 handling a throwable.
java.sql.SQLSyntaxErrorException: ORA-00923: 未找到要求的 FROM 关键字

 

SELECT site_id as id ,MAX(case attr_name when ‘siteName‘ then attr_value END) as siteName,
MAX(case attr_name when ‘userName‘ then attr_value END) as userName,
MAX(case attr_name when ‘password‘ then attr_value END) as password,
MAX(case attr_name when ‘tjSiteId‘ then attr_value END) as tjSiteId,
MAX(case attr_name when ‘tjToken‘ then attr_value END) as tjToken FROM jc_site_attr
where attr_name in (‘siteName‘,‘userName‘,‘password‘,‘tjToken‘,‘tjSiteId‘)
GROUP BY site_id ORDER BY site_id

java.sql.SQLSyntaxErrorException: ORA-00923: 未找到要求的 FROM 关键字

原文:https://www.cnblogs.com/Jeely/p/11199620.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!