SQL> select to_timestamp('2010-12-14:09:56:53') - to_timestamp('2010-12-14:09:56:46') from dua
l;
select to_timestamp('2010-12-14:09:56:53') - to_timestamp('2010-12-14:09:56:46') from dual
*
ERROR at line 1:
ORA-01843: not a valid month
SQL> select to_date('2010-12-14:09:56:53') - to_date('2010-12-14:09:56:46') from dual;
select to_date('2010-12-14:09:56:53') - to_date('2010-12-14:09:56:46') from dual
*
ERROR at line 1:
ORA-01861: literal does not match format string
什麼是做一個ORA-01843 「不是有效的月」 和ORA-01861 「的文字不匹配格式字符串」
2010-12-14:09:56:53
minus
2010-12-14:09:56:46
用Oracle SQL
正確的方法是什麼?
這或許不應該被標記的sqlplus - 怎麼樣,而不是SQL感謝 – 2010-12-14 19:21:45