Hello, I have a strange performance issue.I noticed, that if SQL Server user (SQL login) default language is Finnish, the query is not optimized.When language is English, the performance is as expected.I ran the same query by changing the login language, and by logging in again.There's a query, which I have optimized by adding indexes and statistics by using Database Engine Tuning.When I log in with the same account having English as login language, I get these IO Statistics.Table A. Scan count 230, logical reads 490, physical reads 0, read-ahead reads 0, lob logical reads 0, lob physical reads 0, lob read-ahead reads 0.Table B. Scan count 46, logical reads 138, physical reads 0, read-ahead reads 0, lob logical reads 0, lob physical reads 0, lob read-ahead reads 0.Table C. Scan count 372, logical reads 1129, physical reads 0, read-ahead reads 0, lob logical reads 0, lob physical reads 0, lob read-ahead reads 0.Table D. Scan count 4, logical reads 149, physical reads 0, read-ahead reads 0, lob logical reads 0, lob physical reads 0, lob read-ahead reads 0.Table E. Scan count 1, logical reads 2, physical reads 0, read-ahead reads 0, lob logical reads 0, lob physical reads 0, lob read-ahead reads 0.Table F. Scan count 0, logical reads 2, physical reads 0, read-ahead reads 0, lob logical reads 0, lob physical reads 0, lob read-ahead reads 0.If I change the login language for "Finnish", the IO statistics are the following.Practically no index is used, I guess. I haven't run the SHOWPLAN yet, becuase this account does not have permission on that.Finnish login is required for correct date conversions.Table A. Hakukertoja 230, loogisia lukukertoja 490, fyysisiä lukukertoja 0, ennakoivia lukukertoja 0, loogisia LOB-lukukertoja 0, fyysisiä LOB-lukukertoja 0, ennakoivia LOB-lukukertoja 0.Table B. Hakukertoja 44868, loogisia lukukertoja 89736, fyysisiä lukukertoja 0, ennakoivia lukukertoja 0, loogisia LOB-lukukertoja 0, fyysisiä LOB-lukukertoja 0, ennakoivia LOB-lukukertoja 0.Table C. Hakukertoja 44868, loogisia lukukertoja 135004, fyysisiä lukukertoja 0, ennakoivia lukukertoja 0, loogisia LOB-lukukertoja 0, fyysisiä LOB-lukukertoja 0, ennakoivia LOB-lukukertoja 0.Table D. Hakukertoja 229916, loogisia lukukertoja 698447, fyysisiä lukukertoja 0, ennakoivia lukukertoja 0, loogisia LOB-lukukertoja 0, fyysisiä LOB-lukukertoja 0, ennakoivia LOB-lukukertoja 0.Table E. Hakukertoja 1, loogisia lukukertoja 136020, fyysisiä lukukertoja 0, ennakoivia lukukertoja 0, loogisia LOB-lukukertoja 0, fyysisiä LOB-lukukertoja 0, ennakoivia LOB-lukukertoja 0.Table F. Hakukertoja 0, loogisia lukukertoja 2, fyysisiä lukukertoja 0, ennakoivia lukukertoja 0, loogisia LOB-lukukertoja 0, fyysisiä LOB-lukukertoja 0, ennakoivia LOB-lukukertoja 0.The funniest thing is, that when I change the login language "on the fly", the old connections are still behaving with the performance based on language: Finnish->Slow, English->fast.If create a new connection, I get the speed accordingly.Versions (Running in developer's laptop having Windows 7)Microsoft SQL Server Developer (64-bit)Microsoft Windows NT 6.1 (7601) Version 12.0.4213.0Language: English (United States)Memory: 7619 MBBr,Arto Ojala
↧