70-461 Exam Details

  • Exam Code
    :70-461
  • Exam Name
    :Querying Microsoft SQL Server 2012/2014
  • Certification
    :Microsoft Certifications
  • Vendor
    :Microsoft
  • Total Questions
    :446 Q&As
  • Last Updated
    :Jan 17, 2022

Microsoft 70-461 Online Questions & Answers

  • Question 71:

    You generate a daily report according to the following query:

    The Sales.ufn.GetLastOrderDate user-defined function (UDF) is defined as follows:

    You need to improve the performance of the query. What should you do?

    A. Option A
    B. Option B
    C. Option C
    D. Option D

  • Question 72:

    You use Microsoft SQL Server 2012 to develop a database application.

    You create a stored procedure named DeleteJobCandidate.

    You need to ensure that if DeleteJobCandidate encounters an error, the execution of the stored procedure reports the error number.

    Which Transact-SQL statement should you use?

    A. DECLARE @ErrorVar INT; DECLARE @RowCountVar INT; EXEC DeleteJobCandidate SELECT @ErrorVar = @@ERROR, @RowCountVar = @@ROWCOUNT; IF (@ErrorVar 0) PRINT N'Error = ' + CAST(@@ErrorVar AS NVARCHAR(8)) + N', Rows Deleted = ' + CAST(@RowCountVar AS NVARCHAR(8)); GO
    B. DECLARE @ErrorVar INT; DECLARE @RowCountVar INT; EXEC DeleteJobCandidate SELECT @ErrorVar = ERROR_STATE(), @RowCountVar = @@ROWCOUNT; IF (@ErrorVar 0) PRINT N'Error = ' + CAST(ERROR_STATE() AS NVARCHAR(8)) + N', Rows Deleted = ' + CAST(@RowCountVar AS NVARCHAR(8)); GO
    C. EXEC DeleteJobCandidate IF (ERROR_STATE() != 0) PRINT N'Error = ' + CAST(@@ERROR AS NVARCHAR(8)) + N', Rows Deleted = ' + CAST(@@ROWCOUNT AS NVARCHAR(8)); GO
    D. EXEC DeleteJobCandidate PRINT N'Error = ' + CAST(@@ERROR AS NVARCHAR(8)) + N', Rows Deleted = ' + CAST(@@ROWCOUNT AS NVARCHAR(8)); GO

  • Question 73:

    You use Microsoft SQL Server 2012 to develop a database application. You need to create an object that meets the following requirements:

    -Takes an input variable.

    -

    Returns a table of values Cannot be referenced within a view. Which object should you use?

    A. Scalar-valued function
    B. Inline function
    C. User-defined data type
    D. Stored procedure

  • Question 74:

    You are the database developer at ABC.com. ABC.com has a SQL Server 2012 database infrastructure that has a database named ComDB with tables named Partners and Events. These tables were created using the following Transact-

    SQL code:

    CREATE TABLE [dbo].[Partners]

    (

    [CompanyID] [int] NOT NULL PRIMARY KEY,

    [CompanyName] [varchar] (150) NOT NULL,

    [Location] [varchar] (150) NOT NULL,

    [ContactName] [varchar] (150) NOT NULL,

    [Email] [varchar] (150) NOT NULL,

    [Phone] [varchar] (10) NOT NULL

    )

    CREATE TABLE [dbo].[Events]

    (

    [EventID] [int] NOT NULL PRIMARY KEY,

    [CompanyID] [int] NOT NULL,

    [EventDescription] [nvarchar] (MAX),

    [EventDate] [nvarchar] (50) NOT NULL,

    [EventCordinator] [nvarchar] (150) NOT NULL

    )

    You add a foreign key relationship between the two tables on the CompanyID column.

    You need to develop a stored procedure named sp_coEvents that retrieves CompanyName for all partners and the EventDate for all events that they have coordinated.

    To answer, type the correct code in the answer area.

    A. Check the answer below

  • Question 75:

    Your database contains a table named Customer that has columns named CustomerID and Name. You want to write a query that retrieves data from the Customer table sorted by Name listing 20 rows at a time. You need to view rows 41 through 60. Which Transact-SQL query should you create?

    A. Option A
    B. Option B
    C. Option C
    D. Option D

  • Question 76:

    You use a Microsoft SQL Server 2012 database that contains two tables named SalesOrderHeader and SalesOrderDetail. The indexes on the tables are as shown in the exhibit.

    You write the following Transact-SQL query:

    You discover that the performance of the query is slow. Analysis of the query plan shows table scans where the estimated rows do not match the actual rows for SalesOrderHeader by using an unexpected index on SalesOrderDetail. You need to improve the performance of the query. What should you do?

    A. Use a FORCESCAN hint in the query.
    B. Add a clustered index on SalesOrderId in SalesOrderHeader.
    C. Use a FORCESEEK hint in the query.
    D. Update statistics on SalesOrderId on both tables.

  • Question 77:

    What is the main advantage of batch mode processing?

    A. It lowers the disk I/O.
    B. It speeds up network transfer.
    C. It lowers the CPU burden.
    D. It uses less memory.

  • Question 78:

    DRAG DROP

    You are a developer for a Microsoft SQL Server database. You need to write a stored procedure that performs several operations in the most efficient way possible.

    Which operator or operators should you use? To answer, drag the appropriate operators to the correct operations. Each operator may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to

    view content.

    Select and Place:

  • Question 79:

    Which of the following is applicable to a DELETE statement? (Choose all that apply.)

    A. The statement writes more to the transaction log than TRUNCATE.
    B. The statement resets an IDENTITY property.
    C. The statement is disallowed when a foreign key points to the target table.
    D. The statement is disallowed when an indexed view based on the target table exists.

  • Question 80:

    You use Microsoft SQL Server 2012 database to develop a shopping cart application. You need to invoke a table-valued function for each row returned by a query. Which Transact-SQL operator should you use?

    A. CROSS JOIN
    B. UNPIVOT
    C. PIVOT
    D. CROSS APPLY

Tips on How to Prepare for the Exams

Nowadays, the certification exams become more and more important and required by more and more enterprises when applying for a job. But how to prepare for the exam effectively? How to prepare for the exam in a short time with less efforts? How to get a ideal result and how to find the most reliable resources? Here on Vcedump.com, you will find all the answers. Vcedump.com provide not only Microsoft exam questions, answers and explanations but also complete assistance on your exam preparation and certification application. If you are confused on your 70-461 exam preparations and Microsoft certification application, do not hesitate to visit our Vcedump.com to find your solutions here.