PostgreSQL 问题总结
一、postgresql - server don't listen(服务器未监听)
1)检测是否开启PostgreSQL服务,没开启的话,需要自己手动建立PostgreSQL服务。
2)查看5432端口是否被占用(命令:netstat -na)。被占用的话,需要释放该端口或修改端口。
参考博客 http://i-am-birdman.iteye.com/blog/813226
二、postgresql中 当order by 和distinct同时使用
select distinct typename,type from sys_dicitonary where isvisible=1 and isdelete=0 order by convert_to(typename,'GB18030') ( X ,提示:for SELECT DISTINCT, ORDER BY expressions must appear in select list)
用group by 解决:
select typename,type from sys_dicitonary where isvisible=1 and isdelete=0 group by typename,type order by convert_to(typename,'GB18030') ( √ )