SQLSERVER parameter sniffing

Source: Internet
Author: User
What is SQLSERVER parameter sniffing? When you hear this word, you may feel that it is related to hackers. Use a tool to sniff the parameter and then intercept the parameter, and remove the pants o (_) o. In fact, I think everyone is too sensitive. In fact, this article has nothing to do with database security. In fact, it is related to database performance tuning. I believe that if you have an SQL Server Forum, no.

What is SQLSERVER parameter sniffing? When you hear this word, you may feel that it is related to hackers. Use a tool to sniff the parameter and then intercept the parameter, and remove the pants o (_) o. In fact, I think everyone is too sensitive. In fact, this article has nothing to do with database security. In fact, it is related to database performance tuning. I believe that if you have an SQL Server Forum, no.

SQLSERVER parameter sniffing

When you hear the word "sniffing", you may feel that it is related to hackers. You can use a tool to sniff the parameter, U.S. space, and then intercept the parameter, and remove the pants o.

In fact, I think everyone is too sensitive. The Hong Kong server actually has nothing to do with database security. Hong Kong space is actually related to database performance tuning.

I believe that many of you may have seen the word "parameter sniffing" in the case of an SQL Server forum.

Three posts are about parameter sniffing.

Below I will provide a backup file for the test database, which contains some tables and some test data, you can download it, because the test tables I use below are all in this database

You only need to restore the database. The database is in SQL2005 and the database name is AdventureWorks.

The following uses three tables with indexes:

[Production]. [Product]
[SalesOrderHeader_test]
[SalesOrderDetail_test]

Database download link: AdventureWorks_Full_backup_2013-3-4.bak

In fact, the common explanation of parameter sniffing is that SQL Server cannot sniff specific parameters.

Therefore, he cannot select the most suitable execution plan to execute your query, so parameter sniffing is a bad phenomenon.

To learn more about parameter sniffing, You can first create the following two stored procedures:

Stored Procedure 1:

SniffSniff (@ I INT) (B.),). a. bb... pp..

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.