question

NiklasRAndersen-9370 avatar image
0 Votes"
NiklasRAndersen-9370 asked SaurabhSharma-msft commented

Migrated DB to SQL Azure very slow

Hi!

I migrated a quite simple DB from SQL 2016 to SQL Azure PaaS.

The app server using the DB is also in Azure, same location and RG.

Now when running queries it is extremely slow. Both from the app server, and I also did a test creating 750000 rows:

-onprem server: 5,38 min
-SQL Azure: 42,27 min

All the time the utilization of resources (CPU/IO) are very low (0-3%)

azure-sql-database
· 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.

For the sake of the monitoring please try to choose higher pricing tier with more resources and inform us how this improve your issue

Please provide the current pricing tier which you are using and the exact query which you try to execute

Don't forget that your are on shared environment now and it is expected to have better performance on premises using the same resources

0 Votes 0 ·

1 Answer

AlbertoMorillo avatar image
0 Votes"
AlbertoMorillo answered SaurabhSharma-msft commented

This is typical scenario.

Once you have migrated, make sure you defragment all indexes and update all statistics using Ola Hallengren scripts. Use Azure Automation to make this a daily task.

After that, create missing indexes reported by the T-SQL script shown on this article.

After that you will see performance improvements.



· 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 @niklasrandersen-9370,
Please do not forget to "Accept the answer" wherever the information provided helps you to help others in the community.

Thanks
Saurabh

0 Votes 0 ·