You are the administrator of a SQL Server 2000 database. Using the default options configures the database. You drop indexes to facilitate a large import of data, and rebuild them after the import is complete.
Users report that response times from a stored procedure have become slower. In the stored procedure, you examine the following code.
CREATE PROCEDURE GetCustomer
( @CustomerID Int )
AS
SELECT FirstName, LastName, Address1, Address2, City,
State, Zip, MAX(PurchaseDate) AS LastPurchase
FROM Customers C
JOIN Addresses A ON A.AddressID = C.AddressID
JOIN Purchases P ON P.CustomerID = C.CustomerID
WHERE C.CustomerID = @CustomerID
GROUP BY FirstName, LastName, Address1, Address2, City, State, Zip
You want to improve the performance of the procedure by using the least amount of administrative effort. What should you do?
A.Recompile the stored procedure.
B.Update the database statistics.
C.Check the consistency of the database and repair errors.
D.Create a view and modify the stored procedure to use the view.
第1题:
You are the administrator of a SQL Server 2000 database. You import a table of geographic information from a Microsoft access database into a SQL Server 2000 database. The table has 12,000 rows. Each row averages 5,000 bytes. The table contains lockup data that does not change.
You want to minimize the size of the data file and the time required to back up the data. Which two actions should you take? (Each correct answer presents part of the solution. Choose two)
A. Create a 60-MB data file named geography.ndf
B. Create a 95-MB data file named geography.ndf
C. Create a 60-MB data file named geography.mdf
D. Create a 95-MB data file named geography.mdf
E. Place the table in the PRIMARY filegroup.
F. Place the table in a new filegroup named LOCATION.
第2题:
You are the administrator of a SQL Server 2000 computer. The server contains database named Sales. Users report that they cannot add new data to the database. You examine the properties of the database. The database is configured as shown in the Sales Properties exhibit.
You examine drive E. The hard disk is configured as shown in the Local Disk Properties exhibit.
You want the users to be able to add data, and you want to minimize administrative overhead. What should you do?
A.Increase the maximum file size of Sales_Data to 1,500MB.
B.Use the DBCC SHRINKDATABASE statement.
C.Set automatic file growth to 10 percent.
D.Create another data file named Sales_Data2 in a new SECONDARY filegroup.
第3题:
You are the database administrator for a financial services company. Employees enter data 24 hours a day into a SQL Server 2000 database. These employees report slower response times when new account information is gathered from branch offices and added to the database. You currently use the following BULK INSERT statement to add the account information:
BULK INSERT finance.dbo.customers
FROM ‘di\bulk\accts143_10141000.txt’
WITH DATAFILETYPE = ‘char’,
FIELD/TERMINATOR = ‘\t’,
ROWTERMINATOR = ‘\n,’
TABLOCK
You want to ensure that response times do not slow when new account information is added to the database. What should you do?
A.Drop the indexes for the customers table before the data load, and then re-create the indexes after the data load is complete.
B.Remove the TABLOCK option from the BULK INSERT statement.
C.Add the BATCHSIZE option to the BULK INSERT statement and then set the option equal to 10 percent of the number of rows to be loaded.
D.Add the ROWS_PER_BATCH option to the BULK INSERT statement and then set the option equal to 10 percent of the number of rows to be loaded.
第4题:
You work in a company which uses SQL Server 2008. You are the administrator of the company database. Now you are in charge of a SQL Server 2008 instance. The company wants to export data from SQL Server to a Microsoft Excel file. The company assigns this task to you. You perform this by using the SQL Server Import and Export Wizard. After this, you save the package definition to a file. Now you have to reexecute the package from the command line. In the options below, which utility should you choose to use?()
第5题:
You work in Dublin at the main office of TestKing.com. You are responsible for managing a SQL Server 2005 database. The sales department wants a report that compares customer activity in the previous quarter between the main office in Dublin and the branch office in Buenos Aires. They want the data sorted by surname and first name.You restore a recent backup of the Buenos Aires database onto your server. You write queries to build the report, ordering the data by the Surname and FirstName columns. You review the data and notice that the customer list from the Buenos Aires database is sorted differently. The sales department needs the revised data within 15 minutes for a presentation. You need to implement the fastest possible solution that ensures that the data from both databases is sorted identically. What should you do?()
第6题:
You are the administrator of two SQL Server 2000 computers. One of these servers contains a 4-GB database named marketing. You want to remove the marketing database from one server and add it to the other as quickly as possible.
What should you do?
A.Detach the database from the original server by using the sp_detach_db stored procedure. Copy the database and the transaction log files to the new server, and attach them by using the sp_attach_db stored procedure.
B.Use the DTS export wizard to transfer all database objects from the original server to the new server. Drop the database from the original server.
C.Run a full backup of the database on the original server. Create a new database named marketing on the new server. Restore the backup in the new marketing database. Drop the database from the original server.
D.Shut down the original server. Copy the database and the transaction log files to the new server. Use the DISK INIT and DISK REFIT statements to attach the data file to the new server. Drop the database from the original server.
第7题:
You are the administrator of a new multiprocessor SQL Server 2000 computer. You are migrating data from other database management systems to this server. You need to load data from two data files into a new table on the server. The table is empty and has no indexes.
You want to complete the data load as quickly as possible. What should you do? (Each correct answer represents part of the solution. Choose all that apply.)
A.Apply a bulk update lock to the table.
B.Use separate client connections to load the files into the table simultaneously.
C.Create a clustered index on the table.
D.Specify the Full Recovery model for the database.
E.Specify the Bulk-Logged Recovery model for the database.
第8题:
You are the administrator of a SQL Server 2000 database named Articles. A large city newspaper uses this database to store its archived newspaper articles. Journalists query the database as part of their research. You have created full-text indexes so that users can query the articles quickly.
A hardware failure forces you to restore the entire database from backup. After you restore the database, the journalists report that they can no longer run queries without receiving errors.
You want to ensure that the journalists can query the database. What should you do?
A.Create a new full-text catalog for the Articles database
B.Rebuild the full-text catalog for the Articles database
C.Create a new full-text index on the table that holds the text for the articles
D.Repopulate the full-text index on the table that holds the text for the articles
第9题:
You are planning to import customer data from the Customer table and the Country table in your SQL Server 2000 database into a SQL Server 2005 database. You want to ensure that during the import process,each value in the CountryCode column of the Customer table has a corresponding record in the CountryCode column in the Country table of the SQL Server 2005 database. You define a foreign key between these two tables. Thus,referential integrity will guarantee that the import routine fails if there are any records where a CountryCode value does not exist in the Country table but does exist in the Customer table. You need to ensure that the import process does not fail if records are encountered that do not exist in the Country table. What should you do?()
第10题:
You lost a temporary file that belongs to the default temporary tablespace in your database. From the options provided, which approach would you take to solve the problem? ()