Microsoft 070-461 Actual Free Exam Questions & Community Discussion
You are designing an order entry system that uses an SQL Server database. The database includes the following tables:

You need to ensure that Orders are added to the Orders table only for customers that have an account balance of zero.
How should you complete the relevant Transact-SQL statement? To answer, select the correct Transact-SQL statement from each list in the answer area.


You need to ensure that Orders are added to the Orders table only for customers that have an account balance of zero.
How should you complete the relevant Transact-SQL statement? To answer, select the correct Transact-SQL statement from each list in the answer area.

Correct Answer:

Explanation:
The Transact SQL CREATE TRIGGER command creates a DML, DDL, or logon trigger. A trigger is a special kind of stored procedure that automatically executes when an event occurs in the database server. DML triggers execute when a user tries to modify data through a data manipulation language (DML) event. DML events are INSERT, UPDATE, or DELETE statements on a table or view. These triggers fire when any valid event is fired, regardless of whether or not any table rows are affected.
Partial syntax is:
CREATE TRIGGER [ schema_name . ]trigger_name
ON { table | view }
[ WITH <dml_trigger_option> [ ,...n ] ]
{ FOR | AFTER | INSTEAD OF }
{ [ INSERT ] [ , ] [ UPDATE ] [ , ] [ DELETE ] }
Reference:
https://msdn.microsoft.com/en-us/library/ms189799.aspx
You administer a Microsoft Azure SQL Database instance.
You are writing a new stored procedure that uses explicit transactions.
You need to ensure that no other process can affect the objects being used by the stored procedure while it is running.
Which Transact-SQL statement should you run?
You are writing a new stored procedure that uses explicit transactions.
You need to ensure that no other process can affect the objects being used by the stored procedure while it is running.
Which Transact-SQL statement should you run?
Correct Answer: D
Vote an answer
Explanation: Only visible for EduDump members. You can sign-up / login (it's free).
Your application contains a stored procedure for each country. Each stored procedure accepts an employee identification number through the @EmpID parameter.
You need to build a single process for each employee that will execute the appropriate stored procedure based on the country of residence.
Which approach should you use?
You need to build a single process for each employee that will execute the appropriate stored procedure based on the country of residence.
Which approach should you use?
Correct Answer: C
Vote an answer
Explanation: Only visible for EduDump members. You can sign-up / login (it's free).
Your application contains a stored procedure for each country. Each stored procedure accepts an employee identification number through the @EmpID parameter.
You plan to build a single process for each employee that will execute the stored procedure based on the country of residence.
Which approach should you use?
You plan to build a single process for each employee that will execute the stored procedure based on the country of residence.
Which approach should you use?
Correct Answer: D
Vote an answer
You are developing an employee management database in Microsoft SQL Server. The database contains two tables that are defined with the following Transact-SQL statements:

If the employee qualify for a bonus level they must receive a percentage of any sales.
Select the appropriate from below:


If the employee qualify for a bonus level they must receive a percentage of any sales.
Select the appropriate from below:

Correct Answer:

You have a data warehouse that contains the data for all the customers of your company.
You need to create a stored procedure that generates a list of customer addresses. The list must meet the following requirements:
* The procedure must accept a string value.
* The procedure should return all customers who reside in a city whose name begins with the provided value.
* If a user provides a blank value, the procedure must execute, and then return a blank result set.
Part of the correct Transact-SQL has been provided in the answer area below. Enter the code in the answer area that resolves the problem and meets the stated goals or requirements. You can add code within code that has been provided as well as below it.


Use the 'Check Syntax' button to verify your work. Any syntax or spelling errors will be reported by line and character position.
You need to create a stored procedure that generates a list of customer addresses. The list must meet the following requirements:
* The procedure must accept a string value.
* The procedure should return all customers who reside in a city whose name begins with the provided value.
* If a user provides a blank value, the procedure must execute, and then return a blank result set.
Part of the correct Transact-SQL has been provided in the answer area below. Enter the code in the answer area that resolves the problem and meets the stated goals or requirements. You can add code within code that has been provided as well as below it.


Use the 'Check Syntax' button to verify your work. Any syntax or spelling errors will be reported by line and character position.
Correct Answer: A
Vote an answer
You are maintaining a SQL Server database that uses the default settings. The database contains a table that is defined by the following Transact-SQL statement:

You must write a query that returns the AddressLine1, AddressLine2, and Region fields separated by carriage returns. You must return an empty string for any null values.


You must write a query that returns the AddressLine1, AddressLine2, and Region fields separated by carriage returns. You must return an empty string for any null values.

Correct Answer: D
Vote an answer
Explanation: Only visible for EduDump members. You can sign-up / login (it's free).
You need to create a view named uv_CustomerFullNames. The view must prevent the underlying structure of the customer table from being changed.
Part of the correct T-SQL statement has been provided in the answer area. Provide the complete code.

Part of the correct T-SQL statement has been provided in the answer area. Provide the complete code.

Correct Answer: A
Vote an answer
You develop a Microsoft SQL Server 2012 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?
Correct Answer: B
Vote an answer
0
0
0
10
