关注JEECG发展历程 关注最新动态和版本, 记录JEECG成长点滴 更新日志 - 技术支持 - 招聘英才

JEECG最新版本下载 JEECG智能开发平台 - 显著提高开发效率 常见问题 - 入门视频 - 参与开源团队

商务QQ: 69893005、3102411850 商务热线(5*8小时): 010-64808099 官方邮箱: jeecgos@163.com

查看: 8495|回复: 1

[环境搭建] jeecg切换到postgresql

[复制链接]
发表于 2018-6-15 18:24:23 | 显示全部楼层 |阅读模式
官方文档说jeecg支持postgresql,但是我实际用的时候出现各种问题
1、sql语句的语法不对:SELECT t.* FROM ( select broswer name,count(1) value,case when broswer ='Firefox' then '#FF00FF' when broswer ='IE' then '#FFFF00' else '#43CD80' end color from t_s_log group by broswer ) t
这句在mysql是可以得,pg是不支持的;
2、org.springframework.jdbc.BadSqlGrammarException: PreparedStatementCallback; bad SQL grammar [select * from ( SELECT ID,msg_from as "from" ,msg_to as "to" ,msg_data as "data",create_date,type from jp_chat_message_his where msg_from=? and msg_to=? and type=? UNION ALL SELECT ID, msg_from as "from" ,msg_to as "to" ,msg_data as "data",create_date,type from jp_chat_message_his where msg_from=? and msg_to=? and type=? ORDER BY ID ASC) sel_tab00 limit 0,1000]; nested exception is org.postgresql.util.PSQLException: ERROR: LIMIT #,# syntax is not supported;这个分页也是mysql才支持的,pg不支持这种语法;
3、select * from t_s_depart where org_type = 1,org_type是字符串类型,这个写法mysql支持,pg不支持
这只是部分问题,反正感觉对postgresql支持很差,不知道是不是我的配置有问题,我用的是jeecg-master最新版;
发表于 2018-6-15 19:30:51 | 显示全部楼层
1. 报表这块需要自己根据数据库调整,jeecg只是做例子(jeecg底层兼容各个数据库,报表是大家自己配置)
2.minidao 的数据库类型没改
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

快速回复 返回顶部 返回列表