Share via

Azure SQL Database query performance

Pankaj Joshi 411 Reputation points
2023-03-28T16:05:38.2066667+00:00

I have azure sql database (vcore) . I am running query select col1, col2, col3, col4, col5 where vpkgname ='xxxxxxxxxxxxx' . Please note that non cluster index is already set on where condition col "vpkgname" (nvarchar). This query is reading 2 millions record to fetch specific result in 1.5 second when I am running on azure sql query tool. The same query is taking 0.5 second( half the time) in AWS rds database with similar records. IS THERE ANY recommended database setting I need to check/configure in azure sql database to reduce query time ? Or only option left is to increase vcore size?

Azure SQL Database

Answer accepted by question author

GeethaThatipatri-MSFT 29,597 Reputation points Microsoft Employee Moderator
2023-03-30T21:49:00.36+00:00

@Anonymous Please take a look at this: Default parameterization of varchar to nvarchar in sql driver | by Vinodhini Chockalingam | Medium.

It’s a pretty common issue that can be solved at the config level or in your code, depending on the data access flavor you are using in Spring.

Hope this helps

Regards

Geetha

Was this answer helpful?


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.