Microsoft 70-461 Exam Practice Questions (P. 3)
- Full Access (265 questions)
- Six months of Premium Access
- Access to one million comments
- Seamless ChatGPT Integration
- Ability to download PDF files
- Anki Flashcard files for revision
- No Captcha & No AdSense
- Advanced Exam Configuration
Question #11
Your database contains two tables named DomesticSalesOrders and InternationalSalesOrders. Both tables contain more than 100 million rows. Each table has a
Primary Key column named SalesOrderId. The data in the two tables is distinct from one another.
Business users want a report that includes aggregate information about the total number of global sales and total sales amounts.
You need to ensure that your query executes in the minimum possible time.
Which query should you use?
Primary Key column named SalesOrderId. The data in the two tables is distinct from one another.
Business users want a report that includes aggregate information about the total number of global sales and total sales amounts.
You need to ensure that your query executes in the minimum possible time.
Which query should you use?
- ASELECT COUNT(*) AS NumberOfSales, SUM(SalesAmount) AS TotalSalesAmount FROM ( SELECT SalesOrderId, SalesAmount FROM DomesticSalesOrders UNION ALL SELECT SalesOrderId, SalesAmount FROM InternationalSalesOrders ) AS p
- BSELECT COUNT(*) AS NumberOfSales, SUM(SalesAmount) AS TotalSalesAmount FROM ( SELECT SalesOrderId, SalesAmount FROM DomesticSalesOrders UNION SELECT SalesOrderId, SalesAmount FROM InternationalSalesOrders ) AS p
- CSELECT COUNT(*) AS NumberOfSales, SUM(SalesAmount) AS TotalSalesAmount FROM DomesticSalesOrders UNION SELECT COUNT(*) AS NumberOfSales, SUM(SalesAmount) AS TotalSalesAmount FROM InternationalSalesOrders
- DSELECT COUNT(*) AS NumberOfSales, SUM(SalesAmount) AS TotalSalesAmount FROM DomesticSalesOrders UNION ALL SELECT COUNT(*) AS NumberOfSales, SUM(SalesAmount) AS TotalSalesAmount FROM InternationalSalesOrders
Correct Answer:
A
Reference:
http://msdn.microsoft.com/en-us/library/ms180026.aspx
http://blog.sqlauthority.com/2009/03/11/sql-server-difference-between-union-vs-union-all-optimalperformance-comparison/
A
Reference:
http://msdn.microsoft.com/en-us/library/ms180026.aspx
http://blog.sqlauthority.com/2009/03/11/sql-server-difference-between-union-vs-union-all-optimalperformance-comparison/
send
light_mode
delete
Question #12
You are a database developer at an independent software vendor. You create stored procedures that contain proprietary code.
You need to protect the code from being viewed by your customers.
Which stored procedure option should you use?
You need to protect the code from being viewed by your customers.
Which stored procedure option should you use?
- AENCRYPTBYKEY
- BENCRYPTION
- CENCRYPTBYPASSPHRASE
- DENCRYPTBYCERT
Correct Answer:
B
References:
http://technet.microsoft.com/en-us/library/bb510663.aspx
http://technet.microsoft.com/en-us/library/ms174361.aspx
http://msdn.microsoft.com/en-us/library/ms187926.aspx
http://technet.microsoft.com/en-us/library/ms190357.aspx
http://technet.microsoft.com/en-us/library/ms188061.aspx
B
References:
http://technet.microsoft.com/en-us/library/bb510663.aspx
http://technet.microsoft.com/en-us/library/ms174361.aspx
http://msdn.microsoft.com/en-us/library/ms187926.aspx
http://technet.microsoft.com/en-us/library/ms190357.aspx
http://technet.microsoft.com/en-us/library/ms188061.aspx
send
light_mode
delete
Question #13
You use a Microsoft SQL Server database.
You want to create a table to store Microsoft Word documents.
You need to ensure that the documents must only be accessible via Transact-SQL queries.
Which Transact-SQL statement should you use?
You want to create a table to store Microsoft Word documents.
You need to ensure that the documents must only be accessible via Transact-SQL queries.
Which Transact-SQL statement should you use?
- ACREATE TABLE DocumentStore ( [Id] INT NOT NULL PRIMARY KEY, [Document] VARBINARY(MAX) NULL ) GO
- BCREATE TABLE DocumentStore ( [Id] hierarchyid, [Document] NVARCHAR NOT NULL ) GO
- CCREATE TABLE DocumentStore AS FileTable
- DCREATE TABLE DocumentStore ( [Id] [uniqueidentifier] ROWGUIDCOL NOT NULL UNIQUE, [Document] VARBINARY(MAX) FILESTREAM NULL ) GO
Correct Answer:
A
Reference:
http://msdn.microsoft.com/en-us/library/gg471497.aspx
http://msdn.microsoft.com/en-us/library/ff929144.aspx
A
Reference:
http://msdn.microsoft.com/en-us/library/gg471497.aspx
http://msdn.microsoft.com/en-us/library/ff929144.aspx
send
light_mode
delete
Question #14
You administer a Microsoft SQL Server database that contains a table named OrderDetail. You discover that the NCI_OrderDetail_CustomerID non-clustered index is fragmented. You need to reduce fragmentation.
You need to achieve this goal without taking the index offline. Which Transact-SQL batch should you use?
You need to achieve this goal without taking the index offline. Which Transact-SQL batch should you use?
- ACREATE INDEX NCI_OrderDetail_CustomerID ON OrderDetail.CustomerID WITH DROP EXISTING
- BALTER INDEX NCI_OrderDetail_CustomerID ON OrderDetail.CustomerID REORGANIZE
- CALTER INDEX ALL ON OrderDetail REBUILD
- DALTER INDEX NCI_OrderDetail_CustomerID ON OrderDetail.CustomerID REBUILD
Correct Answer:
B
Reference:
http://msdn.microsoft.com/en-us/library/ms188388.aspx
B
Reference:
http://msdn.microsoft.com/en-us/library/ms188388.aspx
send
light_mode
delete
Question #15
You develop a Microsoft SQL Server database. The database is used by two web applications that access a table named Products.
You want to create an object that will prevent the applications from accessing the table directly while still providing access to the required data.
You need to ensure that the following requirements are met:
✑ Future modifications to the table definition will not affect the applications' ability to access data.
✑ The new object can accommodate data retrieval and data modification.
You need to achieve this goal by using the minimum amount of changes to the existing applications.
What should you create for each application?
You want to create an object that will prevent the applications from accessing the table directly while still providing access to the required data.
You need to ensure that the following requirements are met:
✑ Future modifications to the table definition will not affect the applications' ability to access data.
✑ The new object can accommodate data retrieval and data modification.
You need to achieve this goal by using the minimum amount of changes to the existing applications.
What should you create for each application?
send
light_mode
delete
All Pages