Search This Blog

Database Objective Question (41-50)

Question 41
Jesse's company has a central office and three remote locations. Each remote location has
three to five employees that run an order-taking application; they don't generate any reports
or need any additional data beyond their order-taking application. Each site has a modest but
reliable network connection to the central office. Which of the following is the best way for
Jesse to provide these users with access to the database?

A) Set up snapshot replication to each remote site.
B) Use transactional replication to replicate data to the remote site.
C) Use merge replication to replicate data to the remote site.
D) Don't use replication; just connect the users directly to the remote database.

Question 42
Eric needs to build a stored procedure to count the number of snack food vendors within his
zip code. Which of the following strategies would be the easiest to implement for passing and
returning values?

A) Pass the zip code in as a parameter; pass the number of vendors out as a return value.
B) Pass the zip code in as a parameter; pass the number of vendors out as an output parameter.
C) Use the stored procedure to call a scalar-valued user-defined function.
D) Pass the zip code in as a parameter; pass the output back in a temporary table.

Question 43
Carol wants to distribute the Personnel table, but needs to leave out a couple of columns
from the replication, such as the AnnualSalary column. What's the best way to do this?

A) Implement horizontal partitioning.
B) Use SQL Server security to keep people out of that column.
C) Use vertical partitioning to turn off replication for that article.
D) Use union partitioning.

Question 44
Which of the following are good uses for the I-SQL utility? Choose 2.

A) Execution of Data Definition Language statements
B) Monitor queries issued by one or more users
C) Examine a graphical query plan
D) Schedule execution of a T-SQL script

Question 45
What role do CHECK constraints play in partitioned views?

A) CHECK constraints are required to ensure that an inserted row goes to the correct table.
B) CHECK constraints are not required but can increase performance for inserts to the partitioned view.
C) CHECK constraints serve no purpose for partitioned views.
D) CHECK constraints could conflict with the definition of the partitioned view and therefore
cannot exist on the tables that make up a partitioned view.

Question 46
Which of the following options will create a composite unique index on the CustomerID and ProjectID fields in the CP table?

A) create unique composite index CPidx on CP(CustomerID, ProjectID)
B) create unique index CPidx on CP.CustomerID, CP.ProjectID
C) create unique index CPidx on CP(CustomerID, ProjectID)
D) create clustered index CPidx on CP(CustomerID, ProjectID)


Question 47
Sam needs to set up her stored procedure so that when invalid data values are passed into the
stored procedure, the stored procedure will cause the application to see an error and have
SQL Server log an event into the error log. Which of the following will allow this to happen?

A) ON ERROR RESUME NEXT
B) RAISERROR 'Invalid data', 50000, 1, LOG
C) RAISERROR ('Invalid Data', 50000, 1) WITH LOG
D) RAISERROR('Invalid Data', 50000, 1)

Question 48
Roger wants to create an index on a read-only table. What is the best option
he should use when creating the index?

A) FILLFACTOR = 100
B) FILLFACTOR = 0
C) PAD_INDEX, FILLFACTOR = 100
D) PAD_INDEX, FILLFACTOR = 0

Question 49
When using BCP to transfer data out of a table, which of the following statements apply? Choose 3.

A) Database users will not be able to access the table because BCP will lock it.
B) You must have SELECT permissions on the table.
C) Data changes made by other users during the BCP will not be reflected in the data file.
D) The contents of the data file are replaced if the data file already exists.

Question 50
Insensitive cursors provider what functionality?

A) They enable users to see data inserted since the time the cursor was opened.
B) They allow faster updates because the data for the cursor is stored in tempdb.
C) They cannot be scrolled backward because the data is discarded from the temporary storage after it is fetched.
D) They ensure an unchanging view of the data as it was when the cursor was opened.