各位高手,我在 postgres 8 中用下列语句都很正常,但在 postgres 7版本中就出现错误,哪位高手知道如何解决?谢谢.pc2phone=> select sum(trunc(fcall_time/60)+1) from t_prepaid_history;
ERROR: Function 'trunc(int4)' does not exist
Unable to identify a function that satisfies the given argument types
You may need to add explicit typecasts
ERROR: Function 'trunc(int4)' does not exist
Unable to identify a function that satisfies the given argument types
You may need to add explicit typecasts
解决方案 »
- mysql :Result consisted of more than one row
- 急问: mysql commandline 无法显示中文问题
- 求助,vc6.0下postgresql8.3.4 中文显示乱码?
- mysql的二进制日志怎么打开?
- mysql存储过程 动态拼接语句的问题!!急(寻高手)
- VC6.0连MySQL 5.0数据库问题
- 求sql语句
- delphi刚入门,以前都是用自带的paradox,现在发现好像access还要好些,不知mysql或者sql server,oracle是不是更好?请问大家,用什么数据库更好些,如果考虑到过渡到C/S?
- mysql持续时间段统计难题
- 给mysql数据库的表格添加记录,int格式的字段显示正常,varchar格式的字段显示问号
- 问一个关于MYSQL的replication的问题
- 求救select
不过可以给你建议:
fcall_time/60 返回的一个int 型的。
trunc 的用法是对DOuble precision (也就是双浮点型)型的数进行去尾运算。
你试着把 fcall_time/60 强制转换为 DOuble precision看看。
select sum(trunc((fcall_time/60)::double precision)+1)