Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
daniels13ca
Regular Visitor

change datasoruce

Hello, I have an origin in Access but the data size is very big now, i'm trying to change de datasource to SQL Server and don´t find this option in Power BI Desktop. Is it possible do the migration without remake the dashboard?

Thanks

1 ACCEPTED SOLUTION

Hi @daniels13ca,

 

Seems no direct way available. But we can change the Power Query (M) code directly. One precondition is that the structure should be the same. If they have the same data type, that would be great. 

1. Usually, the first two rows codes are the data source.

2. If you have many queries, you have change them one by one. 

3. Please pay attention to the two parts tagged by blue 1 and 2.

4. Backup the code first, if you do anything wrong, you can paste the code back and do it again.

 

If you have any problem doing it, please post the code here. Please mask the private parts first.

change_datasoruce

 

 

Best Regards,

Dale

Community Support Team _ Dale
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

8 REPLIES 8
rocky09
Solution Sage
Solution Sage

the most challenging part is keeping the same Data format while migration.

1. I would take screenshots of all the data format structures of all tables including the relationships.

2. I will copy the pbix file then start testing it.

3. I will also make sure that all the column names in pbix are noted in some notepad/word.

 

 

My question is that in the options to change de datasource SQL Server is not availableCapture.jpg

 

 

 

@daniels13ca

have you tried to edit through advanced editor in query editor window?

 

found this one

Yes, and the options are the same Man Sad

Hi @daniels13ca,

 

Seems no direct way available. But we can change the Power Query (M) code directly. One precondition is that the structure should be the same. If they have the same data type, that would be great. 

1. Usually, the first two rows codes are the data source.

2. If you have many queries, you have change them one by one. 

3. Please pay attention to the two parts tagged by blue 1 and 2.

4. Backup the code first, if you do anything wrong, you can paste the code back and do it again.

 

If you have any problem doing it, please post the code here. Please mask the private parts first.

change_datasoruce

 

 

Best Regards,

Dale

Community Support Team _ Dale
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

This is the new code:

 

Captura.JPG

ThanksSmiley Very Happy

It is highly unlikely that the data in SQL Database will be in the exact same format as it was when you where pulling data from the Access Database.  As a result there is a very high likelyhood of changes disrupting the report.

 

I woudl strongly suggest you go throught the query editor with a fine tooth comb to ensure, it matches 100%

 

Regards,

Mathew

Mathew101
Frequent Visitor

You would need to work on the Power Query section to ensure that the end tables match what you've had before.  Then in thorey it should work.

 

I have heard a tail that sometimes even when everthing is 100% the same the visiuals need to be rebuilt, I take this with a pinch of salt however.

 

in sure that you have the data tables correct with the correct data types and you should be good to go. 

 

Regards,

Mathew

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.