question

JasonYeung-2529 avatar image
0 Votes"
JasonYeung-2529 asked JasonYeung-2529 answered

Creating relationships between 2 dimensions in ssas

Hi,

I'm trying to create a relationship between 2 dimensions in analysis services. I found this link which tells me how to do this:
https://docs.microsoft.com/en-us/analysis-services/tabular-models/create-a-relationship-between-two-tables-ssas-tabular?view=asallproducts-allversions

I opened the project with Visual Studio (with SQL Server Data Tools installed), but I couldn't find the Model menu that the above link states. Below is a screenshot of what I currently see (I've masked out the table / dimension names):

126390-20210825-data-cubes.jpg



I was wondering if there's another way to create relationships between dimensions in SSAS? Is there a setting I need to change in order to make the Model menu appear (as per the link above). Thanks!

Sincerely,

Jason

sql-server-analysis-services
· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi @JasonYeung-2529, we have not get a reply from you. Could below answers help you? If yes, please do "Accept Answer". By doing so, it will benefit for community members who have this similar issue. Your contribution is highly appreciated. Thank you!

0 Votes 0 ·

Hi @JasonYeung-2529, we have not get a reply from you. Could below answers help you? If yes, please do "Accept Answer". By doing so, it will benefit for community members who have this similar issue. Your contribution is highly appreciated. Thank you!

0 Votes 0 ·
dgosbell avatar image
0 Votes"
dgosbell answered JasonYeung-2529 commented

SSAS supports 2 types of data models, Tabular and Multi-Dimensional. The article you have linked is for a Tabular model, the screen shot you have posted is for a multi-dimensional model.

One way to create a new relationships in multi-dimensional you would just drag a column from one table and drop it onto the column you want to relate it to in the other table. From memory I think it's best to drag the column from the "many" side of the relationship and drop it onto the "one" side.

· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

HI @dgosbell ,

thanks for the clarification. I had a look at the Data Source View to find the dimensions I need to set the relationships, but I couldn't find it. I tried to drag the dimensions into it, but could't. I was wondering if it's possible to add dimensions to the Data Source View?

Jason

0 Votes 0 ·
CarrinWu-MSFT avatar image
0 Votes"
CarrinWu-MSFT answered CarrinWu-MSFT edited

Hi @JasonYeung-2529,

Welcome to Microsoft Q&A!

As dgosbell mentioned, you are using multidimensional model, there have some differences between tabular and multidimensional model, you could refer to this link to get some information about this two models. And also please refer to Defining Relationships Between Dimensions and Measure Groups to get the detail steps.


Best regards,
Carrin


If the answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

CarrinWu-MSFT avatar image
0 Votes"
CarrinWu-MSFT answered CarrinWu-MSFT edited

Hi @JasonYeung-2529,

it's possible to add dimensions to the Data Source View?

No, you cannot add dimensions to data source view. A data source view (DSV) is an abstraction of a relational data source that becomes the basis of the cubes and dimensions you create in a multidimensional project. The purpose of a DSV is to give you control over the data structures used in your project, and to work independently of the underlying data sources (for example, the ability to rename or concatenate columns without directly modifying the original data source). Please refer to Data Source Views in Multidimensional Models.

You could refer to Lesson 5: Defining Relationships Between Dimensions and Measure Groups to learn how to define relationship for different scenario.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

JasonYeung-2529 avatar image
0 Votes"
JasonYeung-2529 answered

Thanks for your help, the both of you. Only 1 answer can be marked as accepted, but all the answers make sense.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.