请问这个统计数据该如何写测试用例?
本帖最后由 kavensyw 于 2010-12-30 10:59 编辑一个很简单的统计,请问如果我当成黑盒来该如何写测试用例,
是在每一层验证2次,难道要验证2**5=32次吗,用不用准备一个数据表格示例,还是如下简单描述?
'******************************************
数据准备: 构造 distinct a.country_id,a.distributor_id,b.organization_id,a.visit_frequency,a.customer_id,a.store_id。 每个至少2组数据
步骤描述: 计算在distinct a.country_id,a.distributor_id,b.organization_id,a.visit_frequency,a.customer_id上统计处的coverage_store值
期望结果:计算值与实际值一致??
'******************************************
还是该怎么办。
逻辑如下:
SELECT a.country_id
,a.distributor_id
,b.organization_id
,p_yearmonth AS yearmonth
,a.visit_frequency
,a.customer_id
,COUNT(DISTINCT a.store_id) AS coverage_store
FROM init_store_scope a
,mdt_organization_distributor b
WHERE a.distributor_id=b.distributor_id(+)
GROUP BY a.country_id
,a.distributor_id
,b.organization_id
,a.visit_frequency
,a.customer_id
页:
[1]