Forum Discussion

Elliott's avatar
Elliott
Advocate II
10 years ago
Solved

Slicer to Cover Different Data Sources

Hello,

 

Simple issue for what I assume should be a simple resolution but can't get my head round it. :smileyfrustrated:

 

I currently have 2 sets of data, from SQL and Excel, in the same report I am creating.

 

However, they both show different types of data, the only common column being 'Date' which is simply displaying a range of dates.

 

Is there any way that I can use 1 slicer on my report for 'Date' that will filter my graphs on both data sources?

 

Regards,

Elliott

7 Replies

  • Bjoern's avatar
    Bjoern
    Continued Contributor

    If the data belongs together, you could create a connection.

     

    1) Import the SQL table into Power BI Desktop

    2) Import excel table into Power BI Desktop

    3) Model relationship between data

     

    4) Create nice and fancy reports

    5) Integrate a slicer based on a column of your choice. ;-)

     

    Please be aware that a join/link on "date" is not the nicest thing to do in most cases. :-]

    • Elliott's avatar
      Elliott
      Advocate II

      Thank you for response, however I did attempt to create relationship before.. receiving the error seen below:

       

      "You can't create a relationship between these two columns because one of the columns must have unique values."

      • Bjoern's avatar
        Bjoern
        Continued Contributor

        Could you please paste an example? I thought you have 2 dimensions with calendar data (=unique values). Otherwise I would try to replace the dates with a ongoing numbre and use it as an idea to join the data.

         

        If the data is otherwise structured, you might have a m:n relationship, which is still a bit tricky in PowerBI, as far as I know.