select min(t_kcsm.tm) as tm,min(t_kcsm.isbn) as isbn,
min(t_kcsl.kccs) as kccs,min(t_kcsm.dj) as dj ,
'[',min(t_kcsm.cbny) as cbny,']',min(t_kcsm.sm) as sm,'[!]',min(t_bb.mc) as bb
from t_kcsm,t_kcsl,t_bb,t_crkls
where t_kcsm.id=t_kcsl.id and t_crkls.id=t_kcsm.id and t_kcsm.bb=t_bb.bh
and t_kcsl.kccs>0 and t_crkls.crkrq>to_date('<?xml:namespace prefix = st1 ns = "urn:schemas-microsoft-com:office:smarttags" />2009-09-01','yyyy-mm-dd')
group by t_kcsm.id;
<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />
select min(t_kcsm.tm) as tm,min(t_kcsm.isbn) as isbn,
min(t_kcsl.kccs) as kccs,min(t_kcsm.dj) as dj ,
'[',min(t_kcsm.cbny) as cbny,']',min(t_kcsm.sm) as sm,'[!]',min(t_bb.mc) as bb
from t_kcsm,t_kcsl,t_bb,t_crkls
where t_kcsm.id=t_kcsl.id and t_crkls.id=t_kcsm.id and t_kcsm.bb=t_bb.bh
and t_kcsl.kccs>0 and t_crkls.crkrq>to_date('2006-11-01','yyyy-mm-dd') and t_crkls.crkrq<to_date('2006-12-01','yyyy-mm-dd')
group by t_kcsm.id;
文章评论(0条评论)
登录后参与讨论