Power BI Desktop 中的关系视图Relationship View in Power BI Desktop

关系视图显示模型中的所有表、列和关系。Relationship View shows all of the tables, columns, and relationships in your model. 这在模型包含许多表且其关系十分复杂时尤其有用。This can be especially helpful when your model has complex relationships between many tables.

让我们来看一下。Let’s take a look.

A.A. 关系视图图标 – 单击可显示关系视图中的模型Relationship View icon – Click to show your model in Relationship View

B.B. 关系 – 可以将光标悬停在关系上方以显示所用列。Relationship – You can hover your cursor over a relationship to show the columns used. 双击关系以在“编辑关系”对话框中将其打开。Double-click on a relationship to open it in the Edit Relationship dialog box.

在上图中,你可以看到 商店 表中有一个与 销售额 表(其中同样含有 StoreKey 列)相关的 StoreKey 列。In the figure above, you can see the Stores table has a StoreKey column that’s related to the Sales table, which also has a StoreKey column. 我们可以看到这是多对一 (*:1) 关系,线中间的图标指出交叉筛选器方向设置为两者We see it’s a Many to One (*:1) relationship, and the icon in the middle of the line shows the Cross filter direction set to Both. 图标上的箭头表示筛选上下文流的方向。The arrow on the icon shows the direction of the filter context flow.

有关关系的详细信息,请参阅在 Power BI Desktop 中创建和管理关系To learn more about relationships, see Create and manage relationships in Power BI Desktop.