Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I have one column that I recently converted to nvarchar(100) to store Asian characters. The other columns in this table, and the other tables in the same database, use varchar, int, bit and datetime. Since that change, some of my queries now take ten to twenty seconds to return less than fifty records. The tables store a thousand records or less.

I've read nvarchar has an associated IO performance cost with it, but this bad for such a small record set? Do I have to adopt an all or nothing approach with nvarchar (convert all varchar to nvarchar) or have I missed something obvious?

share|improve this question
4  
What is the query and the execution plan for one of these 10-20 second queries? –  Martin Smith Nov 26 '12 at 18:54
add comment

1 Answer

Without knowing more details, it's impossible to tell, but you might be suffering from implicit conversion. There are a number of sites with information on the topic that you can use to help troubleshoot your particular query.

The short answer is that no, you should not need to convert all columns to nvarchar. If you are trying to join an nvarchar column to a varchar column, however, you could see a major performance impediment.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.