SQL code:
create table tt
(
msgid int,
logdate datetime,
msg varchar(20)
)
insert into tt
select 1,'2010-05-05 08:30:00.000','hello' union all
select 1,'2010-05-05 09:05:08.000','aaaa' union all
select 1,'2010-05-05 09:30:00.000','bbbb' union all
select 1,'2010-05-05 10:30:00.000','over' union all
select 2,'2010-05-05 10:08:00.000','send' union all
select 2,'2010-05-05 10:10:00.000','accept' union all
select 3,'2010-05-05 11:10:00.000','end'
½á¹û
--------------------------------------------------------------------------------------------------------------
1 hello 2010-05-05 08:30:00.000 aaaa 2010-05-05 09:05:08.000 bbbb 2010-05-05 09:30:00.000 over 2010-05-05 10:30:00.000
2 send 2010-05-05 10:08:00.000 accept 2010-05-05 10:10:00.000
3 end 2010-05-05 11:10:00.000
SQL code:
create table tt
(
msgid int,
logdate datetime,
msg varchar(20)
)
insert into tt
select 1,'2010-05-05 08:30:00.000','hello' union all
select 1,'2010-05-05 09:05:08.000','aaaa' union all
select 1,'2010-05-05 09:30:00.000','bbbb' union all
select 1,'2010-05-05 10:30:00.000','over' union all
select 2,'2010-05-05 10:08:00.000','send' union all
select 2,'2010-05-05 10:10:00.000','accept' union all
select 3,'2010-05-05 11:10:00.000','end'