1. Trang chủ
  2. » Công Nghệ Thông Tin

The Real MTCS SQL Server 2008 Exam 70/432 Prep Kit- P150 pdf

5 181 0

Đang tải... (xem toàn văn)

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 5
Dung lượng 107,99 KB

Nội dung

50 Appendix•SelfTestAppendix operations without losing progress, in case the maintenance operation affects performance severely while it is running. What is the best way to resolve the problem while meeting your objectives? A. Run ALTER INDEX _Orders_CustomerID ON Orders.CustomerID REBUILD B. Run ALTER INDEX IX_Orders_CustomerID ON Orders.CustomerID REORGANIZE C. Run CREATE INDEX IX_Orders_CustomerID ON Orders. CustomerID WITH DROP EXISTING D. Run DBCC INDEXDEFRAG (LOBDatabase, “Orders”, IX_Orders_ CustomerID) Correct Answer & Explanation: B. Specifying the REORGANIZE option with the ALTER INDEX statement slowly rearranges the index in the back- ground without taking it offline. It also allows you to cancel the operation without losing the index and without losing any of the defragmentation that has already taken place. Incorrect Answers & Explanations: A, C, and D. Answer A is incorrect because specifying the REBUILD option with the ALTER INDEX statement will force the index to be taken offline. Answer C is incorrect because dropping and re-creating the index will make the index unavailable to users until the CREATE statement has completed, which may take a long time. Answer D is incorrect because DBCC INDEXDEFRAG is for backwards compatibility only and should not be used in SQL Server 2008. 2. You have recently removed a lot of historical data from your SQL Server 2008 database named HR by archiving it to a different server. However, you notice that the disk space consumed by the database file remains unchanged and the . MDF file is taking up the majority of space on the drive. How can you decrease the size of the database file? A. Run DBCC CHECKDB (‘HR’, REPAIR_ALLOW_DATA_LOSS) B. Run DBCC SHRINKFILE (‘HR_Data’, TRUNCATEONLY) C. Run DBCC SHRINKFILE (‘HR_Data’, NOTRUNCATE) D. Use the Copy Database Wizard to copy the database, then delete the orig- inal database. Finally, rename the new database you have just copied to the same name as the original database. SelfTestAppendix•Appendix 51 Correct Answer & Explanation: B. Running the DBCC SHRINKFILE command with the TRUNCATEONLY option will rearrange the file to put empty space at the end, then truncate the file to shrink it in size. Incorrect Answers & Explanations: A , C, and D. Answer A is incorrect because repairing the database will not shrink the file size nor rearrange the pages in the file to move all empty space to the end. Answer C is incorrect because running the DBCC SHRINKFILE command with the NOTRUNCATE option will rearrange the file to put empty space at the end but will not truncate the file to shrink it in size. The actual file size will remain unchanged. Answer D is incorrect because running the Copy Database Wizard will not shrink the file size. 3. You have a very large table named PhoneSurvey. The table contains a Question column and an Answer column, both of type char(1000). Many questions are similar or the same. Many answers are very similar. Many questions re-phrase the answers. Additionally, many values in the answer column are null. The table resides on a high-performance system, and you are not concerned about query performance. What is the best way to reduce the size of this table as much as possible (choose all that apply)? A. ALTER TABLE PhoneSurvey REBUILD WITH DATA_ COMPRESSION = ROW B. ALTER TABLE PhoneSurvey ALTER COLUMN Answer ADD SPARSE C. ALTER TABLE PhoneSurvey ALTER COLUMN Question ADD SPARSE D. ALTER TABLE PhoneSurvey REBUILD WITH DATA_ COMPRESSION = PAGE Correct Answers & Explanations: B and D. You should enable page-level com- pression on the PhoneSurvey table as this will compress data at row level. Next, apply dictionary compression, which will yield the best compression results. You should also make the Answer column a sparse column to optimize null storage because this column contains many null values. Incorrect Answers & Explanations: A and C. Answer A is incorrect because row level compression will provide less space saving than page compression in this case. Answer D is incorrect because the Question column does not contain a large quantity of null values unlike the answer column. 52 Appendix•SelfTestAppendix 4. Your organization is worried about the security risks of Database Mail and SQL Mail. You are asked to verify that all servers in your organization have these features disabled. If not, you must disable the feature on those servers that don’t have it enabled as soon as possible. What is the best way to accomplish this task with minimum administrative effort? A. Use Policy-Based Management to create a policy condition for the Server Configuration facet, SQLMailEnabled = False OR DatabaseMailEnabled = False. Create a policy linking this condition with a target set. Evaluate the policy to identify servers that don’t comply with this policy. After evalu- ating the policy, apply the policy to reconfigure any noncompliant servers. B. Use Policy-Based Management to create a policy condition for the Server Configuration facet, SQLMailEnabled = False AND DatabaseMailEnabled = False. Create a policy linking this condition with a target set. Evaluate the policy to identify servers that don’t comply with this policy. After evaluating the policy, apply the policy to reconfigure any noncompliant servers. C. Use Policy-Based Management to create a policy with no conditions. Choose to apply this policy to a target set defined by the filter SQLMailEnabled = True OR DatabaseMailEnabled = True. Evaluate the policy to identify servers that don’t comply with this policy. After evalu- ating the policy, manually change the SQL Mail and Database Mail settings to reconfigure any noncompliant servers. D. Use Policy-Based Management to create a policy condition for the Server Configuration facet, SQLMailEnabled = False AND DatabaseMailEnabled = False. Create a policy linking this condition with a target set. Evaluate the policy to identify servers that don’t comply with this policy. After evaluating the policy, manually change the SQL Mail and Database Mail settings to reconfigure any noncompliant servers. Correct Answer & Explanation: B. Creating a policy with SQLMailEnabled = False AND DatabaseMailEnabled = False condition will find all servers that have SQL Mail or Database Mail features enabled and show them as noncompliant. You can then easily apply the policy to reconfigure them with one administrative action. Incorrect Answers & Explanations: A, C, and D. Answer A is incorrect because setting the policy condition to SQLMailEnabled = False OR DatabaseMailEnabled = False will report all servers that have SQL Mail enabled but Database Mail disabled as compliant. Answer C is incorrect SelfTestAppendix•Appendix 53 because you cannot create a policy with no conditions. Answer D is incorrect because reconfiguring server settings manually will take more administrative effort than simply applying the policy. 5. You have created a multistep job to prepare data for an important weekly production report. The job consists of several steps: getting data from multiple servers, consolidating it into a single table, and producing a report. Your users have complained that several times no report was created because certain servers were unavailable. They tell you that they would rather see a report based on last week’s data than not see a report at all. What should you do to satisfy your users? A. Change Step 2: Create Report runs only On Failure of Step 1: Consolidate Data. B. Change Step 2: Create Report runs On Success and On Failure of Step 1: Consolidate Data. C. Rearrange the job steps so that Create Report is Step 1 and Consolidate Data is Step 2. D. Rearrange the job steps so that Step 1: Consolidate Data runs on failure of Step 2: Create Report. Correct Answer & Explanation: B. You must change the execution precedence to always run Step 2: Create Report whether Step 1: Consolidate Data has succeeded or not. Incorrect Answers & Explanations: A, C, and D. Answer A is incorrect because running Step 2 only on failure of Step 1 would mean that no report would be produced if the data was available and the consolidation succeeded with no errors. Answer C is incorrect because changing the order of the steps would mean that the report will always contain previous week’s data, even when the consolidation succeeded. Answer C is incorrect because rearranging the job steps so that Step 1: Consolidate Data runs on failure of Step 2: Create Report could possibly create an infinite loop if the server you are connecting to is not available. 6. You have been asked to produce a report comparing sales activity between the London and São Paulo offices. You restore a backup of the São Paulo sales database on the London SQL Server. You write a query to show sales by product, ordered by product name, and execute it against both databases. You notice that the report based on the São Paulo database is sorted differently. 54 Appendix•SelfTestAppendix The sales department requires your report in 15 minutes. What is the quickest way to make the sort results of both reports consistent? A. Use the Import / Export data wizard to copy the table from the São Paulo database to the London database. B. Use the ALTER TABLE statement to change the collation of the Product Name column in the Product table to the collation used in the London database. C. Use the copy database wizard to copy the database to a new database on the London server, specifying the new collation. D. Use the COLLATE Collation_Name option with the ORDER BY clause for the SELECT statement that the report is based on. Specify the colla- tion of the London server as Collation_Name. Correct Answer & Explanation: D. The COLLATE option can be used in the query you are running on the São Paulo database to specify the collation to use when sorting data. As you want to be consistent with the results of the query against the London database, use the collation of the London database as the collation name. Incorrect Answers & Explanations: A, B, and C. Answer A is incorrect because the Import / Export wizard will take a long time; it is not the quickest way to make the sort results of both reports consistent. Answer B is incorrect because the ALTER TABLE statement will also take a long time. Answer C is incorrect because the copy database wizard does not allow you to change database collation. 7. You have created a maintenance plan named BasicDBMaint and scheduled it to run every Sunday at 10:00 a.m. When you come back to work on Monday, you wonder whether the plan has executed successfully. What are the easiest ways to do this (choose all that apply)? A. In SQL Server Management Studio, expand SQL Server Agent | Maintenance Plans. Right-click BasicDBMaint Maintenance Plan, and click View History. B. Examine the contents of C:\Program Files\Microsoft SQL Server\ MSSQL.1\MSSQL\LOG\ BasicDBMaint_<DateTime> file. C. In SQL Server Management Studio, expand Management | Maintenance Plans. Right-click BasicDBMaint Maintenance Plan, and click View History. . used in SQL Server 2008. 2. You have recently removed a lot of historical data from your SQL Server 2008 database named HR by archiving it to a different server. However, you notice that the disk. table from the São Paulo database to the London database. B. Use the ALTER TABLE statement to change the collation of the Product Name column in the Product table to the collation used in the London. Use the copy database wizard to copy the database to a new database on the London server, specifying the new collation. D. Use the COLLATE Collation_Name option with the ORDER BY clause for the

Ngày đăng: 07/07/2014, 00:20

TỪ KHÓA LIÊN QUAN