易截截图软件、单文件、免安装、纯绿色、仅160KB

当oracle出现 格式与字符串格式不匹配解决办法

    select v.spid spid,v.appid appid,v.version version,v.newversion newversion,v.status status,v.createtime createtime from adc_spversionchangeapply v inner join adc_application a on a.id=v.appid
    where a.create_by = 'a' and v.appid = '12000000005' and  (v.createtime >= '1987-05-06') and (v.createtime <= '2009-04-29')
加入v.createtime在数据库中试date类型  那么会跑出异常
ORA-01861: 文字与格式字符串不匹配
实际上是因为 '1987-05-06'是字符串类型导致的date类型与字符串类型 件跨类型比较 所以是有问题的
将'1987-05-06'  写成to_date('1987-09-18','yyyy-mm-dd')
就行了
代码如下
    select v.spid spid,v.appid appid,v.version version,v.newversion newversion,v.status status,v.createtime createtime from adc_spversionchangeapply v inner join adc_application a on a.id=v.appid
    where a.create_by = 'a' and v.appid = '12000000005' and  (v.createtime >= to_date('1987-05-12','yyyy-mm-dd')) and (v.createtime <= to_date( '2009-04-29','yyyy-mm-dd')


相关文档:

Oracle 10g RAC On Linux Using NFS

http://inthirties.com:90/thread-918-3-1.html
This article describes the installation of
Oracle 10g release 2 (10.2.0.1) RAC on Linux (Oracle Enterprise Linux
4.5) using NFS to provide the shared storage.
Introduction
Download Software
Operating System Installation
Oracle Installation Prereq ......

SQLServer和Oracle的常用函数对比

SQLServer和Oracle的常用函数对比
 
1.绝对值
S:select abs(-1) value
O:select abs(-1) value from dual
 
2.取整(大)
S:select ceiling(-1.001) value
O:select ceil(-1.001) value from dual
 
3.取整(小)
S:select floor(-1.001) value
O:select floor(-1.001) value from dual ......

Oracle数据导入导出详解

将一个数据库的某用户的所有表导到另外数据库的一个用户下面的例子  
exp userid=system/manager owner=username1 file=expfile.dmp
imp userid=system/manager fromuser=username1 touser=username2 ignore=y file=expfile.dmp
ORACLE数据库有两类备份方法。第一类为物理备份,该方法实现数据库的完整恢复,但数据 ......

ORACLE数据库的基本语法集锦

ORACLE数据库的基本语法集锦
 
-- 表
create table test (names varchar2(12),
                   dates date,
               &nb ......

Oracle中利用Trigger进行工作

Oracle数据库中,有些情况下,对数据记录需要记录日志,或保存操作历史等情况.在此我们可以借助“数据库Trigger”进行。下面以一例进行说明:
CREATE OR REPLACE TRIGGER aits_auth_group_auth_trga_diu
  AFTER update OR DELETE OR  INSERT on  aits_authority_group_auth
  for each row ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号