|
hehe
如果字符集中的日期格式设置的不一样,取不出来很正常.有本事两边的格式都一样,你看看.
17:34:57 SQL> create table test_temp (name varchar2(8),age number,insertdate date);
Table created.
Elapsed: 00:00:00.04
17:35:07 SQL> insert into test_temp values('aaron',29,sysdate);
1 row created.
17:36:03 SQL> select * from test_temp where to_char(insertdate) = '2007-11-30';
no rows selected
我的
select * from test_temp where to_char(insertdate,'yyyy-mm-dd') = '2007-11-30'; |
|