eas查询分析器查询6500行后的数据
Posted 凉了记忆
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了eas查询分析器查询6500行后的数据相关的知识,希望对你有一定的参考价值。
分析函数指定行号(rowno),最后按照行号筛选数据即可;
脚本中使用了Oracle数据库方言(特有函数),执行SQL时需加上方言标记(/*dialect*/),具体查询脚本请参考下文。--查询前5000行
/*dialect*/
select * from (select t.*, row_number() over (order by t.PATIENT_CODE) rowno from (
select distinct cus.FID ID, cus.FNumber PATIENT_CODE, cus.FName_L2 SURE_NAME,
(case crm.FCustSex when 0 then \'M\' when 1 then \'F\' else \'-\' end) SEX_TYPE, --性别
to_char(crm.CFBirthday, \'yyyy-MM-dd\') BIRTHDAY, --生日
crm.CFDefaultPhone MOBILE_PHONE, crm.FDefaultTel HOME_PHONE, --手机号、备用号
cou.FName_L2 COUNTRY, folk.FName_L2 NATIONALITY, --国家、民族
org.FNumber ORGNO, org.FName_L2 ORGNAME --财务组织编码、名称
from T_BD_Customer cus --客户主数据
inner join T_BD_CSSPGroup grp on cus.FBrowseGroupID = grp.FID --客户分类
inner join T_MS_CustomerCrmInfo crm on cus.FID = crm.FCustomerID --客户CRM信息
inner join T_ORG_Company org on crm.FFICompanyID = org.FID --财务组织
left join T_BD_Country cou on crm.CFCountryID = cou.FID --国家
left join T_BD_HRFolk folk on crm.FNationID = folk.FID --民族
where grp.FNumber in (\'001\', \'002\', \'003\') --限定客户分类
and cus.FUsedStatus = 1 --核准状态
and org.FNumber = \'1001\' --财务组织编码
) t) where rowno < 5001--查询5001到10000行
/*dialect*/
select * from (select t.*, row_number() over (order by t.PATIENT_CODE) rowno from (
select distinct cus.FID ID, cus.FNumber PATIENT_CODE, cus.FName_L2 SURE_NAME,
(case crm.FCustSex when 0 then \'M\' when 1 then \'F\' else \'-\' end) SEX_TYPE, --性别
to_char(crm.CFBirthday, \'yyyy-MM-dd\') BIRTHDAY, --生日
crm.CFDefaultPhone MOBILE_PHONE, crm.FDefaultTel HOME_PHONE, --手机号、备用号
cou.FName_L2 COUNTRY, folk.FName_L2 NATIONALITY, --国家、民族
org.FNumber ORGNO, org.FName_L2 ORGNAME --财务组织编码、名称
from T_BD_Customer cus --客户主数据
inner join T_BD_CSSPGroup grp on cus.FBrowseGroupID = grp.FID --客户分类
inner join T_MS_CustomerCrmInfo crm on cus.FID = crm.FCustomerID --客户CRM信息
inner join T_ORG_Company org on crm.FFICompanyID = org.FID --财务组织
left join T_BD_Country cou on crm.CFCountryID = cou.FID --国家
left join T_BD_HRFolk folk on crm.FNationID = folk.FID --民族
where grp.FNumber in (\'001\', \'002\', \'003\') --限定客户分类
and cus.FUsedStatus = 1 --核准状态
and org.FNumber = \'1001\' --财务组织编码
) t) where rowno between 5001 and 10000
linux下的docker操作命令及异常
以上是关于eas查询分析器查询6500行后的数据的主要内容,如果未能解决你的问题,请参考以下文章
SQL Server 2008 R2,查询在 65536 行后退出
请教EA6500v2刷了AdvancedTomato,如何安装ss插件fan wall用