Find SQL:
VIEW SERVER STATE privilege: View the plan cache.
Manage Plan Guide:
ALTER privilege: Change some objects in the database.
EXECUTE privilege: Execute SQL.
SHOWPLAN privilege: Get the plan of the SQL.
REFERENCES privilege: Refer the database object normally.
ALTER privilege: Change some objects in the database.
ALTER SERVER STATE privilege: Validate the plan guide.
Optimize Indexes:
Server role of sysadmin and Database role of db_owner or db_ddladmin: Create an index.
CREATE TABLE on tempdb privilege: Create a temporary table.
SHOWPLAN privilege: Get the plan of the SQL.
SELECT on tempdb privilege: Query the temporary tables.
VIEW SERVER STATE privilege: View the plan cache.
Optimize SQL:
CREATE TABLE on tempdb privilege: Create a temporary table.
SHOWPLAN privilege: Get the plan of the SQL.
REFERENCES privilege: Refer the database object normally.
SELECT on tempdb privilege: Query the temporary tables.
EXECUTE privilege: Execute SQL.
Server role of sysadmin and Database role of db_owner or db_ddladmin: Get schema information.
Optimize SQL (Plan Control Mode):
ALTER privilege: Change some objects in the database.
Optimize SQL (Rewrite Mode):
Server role of sysadmin and Database role of db_owner or db_ddladmin: Create an index.
Scan SQL:
CREATE TABLE on tempdb privilege: Create a temporary table.
SELECT on tempdb privilege: Query the temporary tables.
SHOWPLAN privilege: Get the plan of the SQL.