我正在尝试帮助一位同事在Excel中进行一些工作,他有一个包含40个组织的数据集,其中每个组织都有多个关键个人(KP)。对于这些KP中的每一个,都针对3个关键标准区域(在这些区域中给出Y或N)进行了评估,这些标准是:
数据示例显示在屏幕快照中链接
我要实现的目标是建立一个“过滤器表格”,该表格将允许个人提出要求(例如,西部地区的老年护理经验),并获得组织的输出结果,符合此条件。
我已经尝试通过使用数据透视表来实现此目的,但是由于标准不同以及每个组织都有多个KP的事实,我没有运气。
无论是否可以在Excel中实际完成以及如何完成,任何帮助都将不胜感激。如果不能,我在考虑是否可以使用Access数据库。
更新: 请参阅附件中donPablo要求的示例数据摘录 Data Extract
从与我的同事的讨论中,对他来说最好的结果是获得供应商,KP和其他标准(认为这是隐藏所有组织和KP期望满足条件的过滤器)。
如果这无法实现,我可以想象拥有组织名称和KP作为输出(满足标准)就足够了。
答案 0 :(得分:0)
Think about maintenance of the ExampleData...
Adding a new Industry. Adding a new Expertise.
Splitting Industry into 3 Industry-s
Adding new Org with 2 KP
Deleting old KP3 from an org
For now with the initial concept, changes are small.
But soon in growth period there will be many changes.
How do you distribute these changes to all the users?
Thus, some sort of Split solution is needed.
A back-end DB (XLS or MSACCESS or SQLSERVER) ,
and a front-end form for--
Selection(s)
Results
Back-end as XLS could still be as ExampleData...
To be kept in central office.
And a front-end that links or references that db
but does not contain all the detail rows.
I think that the main matrix needs another column
called AreaType, value G or I or E
and that the area heading row needs to say
'ANY Geo" and have all "Y"-s in each column, etc for I and E.
In searching the matrix for Aged Care we should only look at Industry.
The ANY row would be chosen when the user does not choose an area.
I think that "Org" is a separate table
And that "KP" is another separate table.
This allows full details to be stored elsewhere
than the main matrix of areas.
Column heading of matrix would be "Org#~KP#", which would be
parsed on the tilde and separately looked up.
(it is improbable that any org or kp will have a tilde).
Yes, it is possible to search the matrix and retrieve qualified rows.
For ncol = minCol to maxCol
CountYInG = 0: CountYInI = 0: CountYInE = 0:
For each AreaType G, I, E
' then look at what was selected (gggg/iiii/eeee)
For each AreaName in (gggg/iiii/eeee)
If matrix = "Y" then add 1 to Count
next
next
if CountYInG > 0 and CountYInI > 0 and CountYInE > 0 then
This Org/KP qualifies
endif
next
添加Pi日20:00 首先倾向于不要有3个标准表(G / I / E),而要有一个表。
让我们进行几种替代的数据库设计。然后查看用法,并对它们进行排名。 最后选择一个并执行。祝你好运,再见。
Matrix alternative
MatrixTable--AreaType & AreaName (PK), and one attribute Column for each Org/KP with value 'Y' or blank.
1st row has PK=C-ColHeadings, and each Column has Org#/KP# for that column.
OrgTable--Org# (PK), and OrgName, OrgStreet1, OrgStreet2, OrgCity/State/Zip, OrgPhone, ...
KPTable --KP# (PK), and KPName, KPOrg#, KPPhone
Normalized alternative (Admin would need to do pivot to see matrix view)
DetailTable--Org#(FK)-KP#(FK)-AreaType-AreaName(FK) DetailValue = 'Y' or ('Y' by implication of row existance)
OrgTable--Org# (PK), and OrgName, OrgStreet1, OrgStreet2, OrgCity/State/Zip, OrgPhone, ...
KPTable --KP# (PK), and KPName, KPOrg#, KPPhone
AreaTable--AreaType-AreaName(PK) (so that everyone spells it the same)
Your favorite design... list the tables, and their fields