Re: SQL statement problem
Date: Thu, 30 Aug 2001 01:10:46 +0900
Message-ID: <9ZHIIQKMBHA.351_at_news2.sys.netsgo.com>
SQL> create table test(
2 department varchar2(20),
3 depdate date);
Table created.
1 row created.
SQL> insert into test
1 row created.
SQL> insert into test
1 row created.
SQL> select * from test;
DEPARTMENT DEPDATE
I've just made sample table.
SQL> select * from test
DEPARTMENT DEPDATE
Be happy all the time!!
"Calvin" <calvin_at_isidasia.com.hk> wrote in message
news:9mi1kv$qbd$1_at_news.hk.linkage.net...
SQL> insert into test
2 values('admin', '11-jun-90');
2 values('purchasing', '06-aug-97'); <--- means 2097year.
2 values('development', '12-sep-1997');
-------------------- ---------
admin 11-JUN-90
purchasing 06-AUG-97
development 12-SEP-97
If you want department started in 1997 or 2097,
you can use LIKE operator.
2 where depdate like '%97';
-------------------- ---------
purchasing 06-AUG-97
development 12-SEP-97
from zeni~~~
> Dear all,
>
> I am a student but have some problem about the assignment !
> I hope someone can ans me !!!
>
> I have the date field in table,
> eg. department depdate
> admin l1-JUN-90
> purchasing 06-AUG-97
> development 12-Sept-97
>
> now I want select the department start in 1997.
> how to write SQL statement in specify the Year is ??
>
> Thanks
> Calvin
>
>
>
Received on Wed Aug 29 2001 - 18:10:46 CEST