union all sql

select sp_id,
       calling_id,
       owner_area_code,
       dr_day,
       period_id,
       prod_id,
       service_id,
       test_flag,
       service_type_id,
       fee,
       duration,
       LOCAL_UNITS,
       charge_units,
       acct_TYPE_ID,
       location_id,
       dr_source
  from DAT_DR_200701
 where dr_day between '20070118' and '20070405'
union all
select sp_id,
       calling_id,
       owner_area_code,
       dr_day,
       period_id,
       prod_id,
       service_id,
       test_flag,
       service_type_id,
       fee,
       duration,
       LOCAL_UNITS,
       charge_units,
       acct_TYPE_ID,
       location_id,
       dr_source
  from DAT_DR_200702
 where dr_day between '20070118' and '20070405'
union all
select sp_id,
       calling_id,
       owner_area_code,
       dr_day,
       period_id,
       prod_id,
       service_id,
       test_flag,
       service_type_id,
       fee,
       duration,
       LOCAL_UNITS,
       charge_units,
       acct_TYPE_ID,
       location_id,
       dr_source
  from DAT_DR_200703
 where dr_day between '20070118' and '20070405'
union all
select sp_id,
       calling_id,
       owner_area_code,
       dr_day,
       period_id,
       prod_id,
       service_id,
       test_flag,
       service_type_id,
       fee,
       duration,
       LOCAL_UNITS,
       charge_units,
       acct_TYPE_ID,
       location_id,
       dr_source
  from DAT_DR_200704
 where dr_day between '20070118' and '20070405'

posted on 2007-05-28 16:54 五味子 阅读(246) 评论(0)  编辑  收藏 所属分类: USBOSS-SQL


只有注册用户登录后才能发表评论。


网站导航:
博客园   IT新闻   Chat2DB   C++博客   博问  
 

导航

<2025年6月>
25262728293031
1234567
891011121314
15161718192021
22232425262728
293012345

统计

留言簿

随笔分类

文章分类

文章档案

搜索

最新评论