2026 New 70-761 Exam Dumps with PDF and VCE Free: https://www.2passeasy.com/dumps/70-761/

We offers . "Querying Data with Transact-SQL (beta)", also known as 70-761 exam, is a Microsoft Certification. This set of posts, Passing the 70-761 exam with , will help you answer those questions. The covers all the knowledge points of the real exam. 100% real and revised by experts!

Microsoft 70-761 Free Dumps Questions Online, Read and Test Now.

NEW QUESTION 1
You need to develop a function that returns a list of courses grouped by the total number of students in a course.
The function must list only courses that have more than a specific number of students. The specific number of students is defined as an input variable for the function.
How should you complete the function? To answer, select the appropriate Transact-SQL segments in the answer area.
NOTE: Each correct selection is worth one point.
70-761 dumps exhibit

    Answer:

    Explanation: 70-761 dumps exhibit

    NEW QUESTION 2
    Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.
    After you answer a question in this section. You will NOT be able to return to it. As a result, these questions will not appear in the review screen.
    A database has two tables as shown in the following database diagram:
    70-761 dumps exhibit
    You need to list all provinces that have at least two large cities. A large city is defined as having a population of at least one million residents. The query must return the following columns:
    70-761 dumps exhibit
    Solution: You run the following Transact-SQL statement:
    70-761 dumps exhibit
    Does the solution meet the goal?

    • A. Yes
    • B. No

    Answer: A

    Explanation: The requirement to list all provinces that have at least two large cities is meet by the WHERE CitySummary.LargeCityCount >=2 clause.
    CROSS APPLY will work fine here. Note:
    The APPLY operator allows you to invoke a table-valued function for each row returned by an outer table expression of a query. The table-valued function acts as the right input and the outer table expression acts as the left input. The right input is evaluated for each row from the left input and the rows produced are combined for the final output. The list of columns produced by the APPLY operator is the set of columns in the left input followed by the list of columns returned by the right input.
    There are two forms of APPLY: CROSS APPLY and OUTER APPLY. CROSS APPLY returns only rows from the outer table that produce a result set from the table-valued function. OUTER APPLY returns both rows that produce a result set, and rows that do not, with NULL values in the columns produced by the table-valued function.
    References: https://technet.microsoft.com/en-us/library/ms175156(v=sql.105).aspx

    NEW QUESTION 3
    Note: This question is part of a series of questions that use the same or similar answer choices. An answer choice may be correct for more than one question in the series. Each question is independent of the other questions in this series. Information and details provided in a question apply only to that question.
    You have a database that contains several connected tables. The tables contain sales data for customers in the United States only.
    You have the following partial query for the database. (Line numbers are included for reference only.)
    70-761 dumps exhibit
    You need to complete the query to generate the output shown in the following table.
    70-761 dumps exhibit
    Which statement clause should you add at line 3?

    • A. GROUP BY
    • B. MERGE
    • C. GROUP BY ROLLUP
    • D. LEFT JOIN
    • E. GROUP BY CUBE
    • F. CROSS JOIN
    • G. PIVOT
    • H. UNPIVOT

    Answer: F

    Explanation: A cross join that does not have a WHERE clause produces the Cartesian product of the tables involved in the join. The size of a Cartesian product result set is the number of rows in the first table multiplied by the number of rows in the second table.
    References: https://technet.microsoft.com/en-us/library/ms190690(v=sql.105).aspx

    NEW QUESTION 4
    You have a database that includes the tables shown in the exhibit. (Click the exhibit button.)
    70-761 dumps exhibit
    You need to create a list of all customers, the order ID for the last order that the customer placed, and the date that the order was placed. For customers who have not placed orders, you must substitute a zero for the order ID and 01/01/1990 for the date.
    Which Transact-SQL statement should you run?
    70-761 dumps exhibit

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

    Answer: A

    Explanation: ISNULL Syntax: ISNULL ( check_expression , replacement_value ) author:"Luxemburg, Rosa"
    The ISNULL function replaces NULL with the specified replacement value. The value of check_expression is returned if it is not NULL; otherwise, replacement_value is returned after it is implicitly converted to the type of check_expression.
    References: https://msdn.microsoft.com/en-us/library/ms184325.aspx

    NEW QUESTION 5
    Note: This question is part of a series of questions that use the same scenario. For your convenience, the scenario is repeated in each question. Each question presents a different goal and answer choices, but the text of the scenario is exactly the same in each question in this series.
    Start of repeated scenario
    You have a database that contains the tables shown in the exhibit. (Click the Exhibit button.)
    70-761 dumps exhibit
    You review the Employee table and make the following observations:
    - Every record has a value in the ManagerID except for the Chief Executive Officer (CEO).
    - The FirstName and MiddleName columns contain null values for some records.
    - The valid values for the Title column are Sales Representative manager, and CEO. You review the SalesSummary table and make the following observations:
    - The ProductCode column contains two parts: The first five digits represent a product code, and the last seven digits represent the unit price. The unit price uses the following pattern: ####.##.
    - You observe that for many records, the unit price portion of the ProductCode column contains values.
    - The RegionCode column contains NULL for some records.
    - Sales data is only recorded for sales representatives.
    You are developing a series of reports and procedures to support the business. Details for each report or procedure follow.
    Sales Summary report: This report aggregates data by year and quarter. The report must resemble the following table.
    70-761 dumps exhibit
    Sales Manager report: This report lists each sales manager and the total sales amount for all employees that report to the sales manager.
    Sales by Region report: This report lists the total sales amount by employee and by region. The report must include the following columns: EmployeeCode, MiddleName, LastName, RegionCode, and SalesAmount. If MiddleName is NULL, FirstName must be displayed. If both FirstName and MiddleName have null values, the world Unknown must be displayed/ If RegionCode is NULL, the word Unknown must be displayed.
    Report1: This report joins data from SalesSummary with the Employee table and other tables. You plan to create an object to support Report1. The object has the following requirements:
    - be joinable with the SELECT statement that supplies data for the report
    - can be used multiple times with the SELECT statement for the report
    - be usable only with the SELECT statement for the report
    - not be saved as a permanent object
    Report2: This report joins data from SalesSummary with the Employee table and other tables. You plan to create an object to support Report1. The object has the following requirements:
    Sales Hierarchy report. This report aggregates rows, creates subtotal rows, and super-aggregates rows over the SalesAmount column in a single result-set. The report uses SaleYear, SaleQuarter, and SaleMonth as a hierarchy. The result set must not contain a grand total or cross-tabulation aggregate rows.
    Current Price Stored Procedure: This stored procedure must return the unit price for a product when a product code is supplied. The unit price must include a dollar sign at the beginning. In addition, the unit price must contain a comma every three digits to the left of the decimal point, and must display two digits to the left of the decimal point. The stored procedure must not throw errors, even if the product code contains invalid data.
    End of Repeated Scenario
    You are creating the queries for Report1 and Report2.
    You need to create the objects necessary to support the queries.
    Which object should you use to join the SalesSummary table with the other tables that each report uses? To answer, drag the appropriate objects to the correct reports. each object 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.
    70-761 dumps exhibit

      Answer:

      Explanation: Box 1: common table expression (CTE)
      A common table expression (CTE) can be thought of as a temporary result set that is defined within the execution scope of a single SELECT, INSERT, UPDATE, DELETE, or CREATE VIEW statement. A CTE is similar to a derived table in that it is not stored as an object and lasts only for the duration of the query. Unlike a derived table, a CTE can be self-referencing and can be referenced multiple times in the same query.
      A CTE can be used to:
      From Scenario: Report1: This report joins data from SalesSummary with the Employee table and other tables. You plan to create an object to support Report1. The object has the following requirements:
      Box 2: view
      From scenario: Report2: This report joins data from SalesSummary with the Employee table and other tables. You plan to create an object to support Report1. The object has the following requirements:
      References: https://technet.microsoft.com/en-us/library/ms190766(v=sql.105).aspx

      NEW QUESTION 6
      Note: This question is part of a series of questions that use the same or similar answer choices. An answer choice may be correct for more than one question in the series. Each question is independent of the other questions in this series. Information and details provided in a question apply to that question.
      You have a database for a banking system. The database has two tables named tblDepositAcct and tblLoanAcct that store deposit and loan accounts, respectively. Both tables contain the following columns:
      70-761 dumps exhibit
      You need to determine the total number of customers who have only loan accounts. Which Transact-SQL statement should you run?

      • A. SELECT COUNT(*)FROM (SELECT AcctNoFROM tblDepositAcctINTERSECTSELECTAcctNoFROM tblLoanAcct) R
      • B. SELECT COUNT(*)FROM (SELECT CustNoFROM tblDepositAcctUNIONSELECT CustNoFROMtblLoanAcct) R
      • C. SELECT COUNT(*)FROM (SELECT CustNoFROM tblDepositAcctUNION ALLSELECTCustNoFROM tblLoanAcct) R
      • D. SELECT COUNT (DISTINCT D.CustNo)FROM tblDepositAcct D, tblLoanAcct LWHERE D.CustNo= L.CustNo
      • E. SELECT COUNT(DISTINCT L.CustNo)FROM tblDepositAcct DRIGHT JOIN tblLoanAcct L ON D.CustNo = L.CustNoWHERE D.CustNo IS NULL
      • F. SELECT COUNT(*)FROM (SELECT CustNoFROM tblDepositAcctEXCEPTSELECT CustNoFROMtblLoanAcct) R
      • G. SELECT COUNT (DISTINCT COALESCE(D.CustNo, L.CustNo))FROM tblDepositAcct DFULLJOIN tblLoanAcct L ON D.CustNo = L.CustNoWHERE D.CustNo IS NULL OR L.CustNo IS NULL
      • H. SELECT COUNT(*)FROM tblDepositAcct DFULL JOIN tblLoanAcct L ON D.CustNo = L.CustNo

      Answer: E

      Explanation: The RIGHT JOIN keyword returns all records from the right table (table2), and the matched records from the left table (table1). The result is NULL from the left side, when there is no match.
      References: https://www.w3schools.com/sql/sql_join_right.asp

      NEW QUESTION 7
      You have a database that contains a table named Users. The table is defined as follows:
      70-761 dumps exhibit
      You have the following Comma Separated Values (CSV) file:
      70-761 dumps exhibit
      You need to load data from the CSV file into the Users table while meeting the following requirements:
      If a field value is not provided in the file, insert a NULL value for the corresponding column
      Load all records into the table with the correct UserId from the file
      Which three Transact-SQL segments should you use to develop the solution? To answer, move the appropriate Transact-SQL segments from the list of Transact-SQL segments to the answer area and arrange them in the correct order.
      70-761 dumps exhibit

        Answer:

        Explanation: 70-761 dumps exhibit

        NEW QUESTION 8
        Note: This question is part of a series of questions that use the same scenario. For your convenience, the scenario is repeated in each question. Each question presents a different goal and answer choices, but the text of the scenario is exactly the same in each question in this series.
        You query a database that includes two tables: Project and Task. The Project table includes the following columns:
        70-761 dumps exhibit
        70-761 dumps exhibit
        You need to identify the owner of each task by using the following rules:
        - Return each task’s owner if the task has an owner.
        - If a task has no owner, but is associated with a project that has an owner, return the project’s owner.
        - Return the value -1 for all other cases.
        How should you complete the Transact-SQL statement? To answer, select the appropriate Transact-SQL segments in the answer area.
        70-761 dumps exhibit

          Answer:

          Explanation: Box 1: COALESCE
          COALESCE evaluates the arguments in order and returns the current value of the first expression that initially does not evaluate to NULL.
          Box 2: T.UserID, p.UserID, -1
          - Return each task’s owner if the task has an owner.
          - If a task has no owner, but is associated with a project that has an owner, return the project’s owner.
          - Return the value -1 for all other cases. Box 3: LEFT JOIN
          The LEFT JOIN keyword returns all rows from the right table (table2), with the matching rows in the left table (table1). The result is NULL in the left side when there is no match. Here the right side could be NULL as the projectID of the task could be NULL.
          References:
          https://msdn.microsoft.com/en-us/library/ms190349.aspx
          http://www.w3schools.com/Sql/sql_join_right.asp

          NEW QUESTION 9
          You run the following Transact-SQL statement:
          70-761 dumps exhibit
          You need to create a stored procedure that meets the following requirements:
          Inserts data into the Employees table.
          Processes all data changes as a single unit of work.
          Sets the exception severity level to 16 and an error number of 60, 000 when any error occurs.
          If a Transact-SQL statement raises a runtime error, terminates and reverts the entire unit of work, and indicates the line number in the statement where the error occurred.
          Inserts the value New Employee for the Title column if no title is provided.
          How should you complete the Transact-SQL statement? To answer, drag the appropriate Transact-SQL segment to the correct target. Each Transact-SQL segment 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.
          NOTE: Each correct selection is worth one point.
          70-761 dumps exhibit

            Answer:

            Explanation: 70-761 dumps exhibit

            NEW QUESTION 10
            Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.
            After you answer a question in this section. you will NOT be able to return to it. As a result, these questions will not appear in the review screen.
            You have a database that tracks orders and deliveries for customers in North America. The database contains the following tables:
            Sales.Customers
            70-761 dumps exhibit
            Application.Cities
            70-761 dumps exhibit
            Sales.CustomerCategories
            70-761 dumps exhibit
            The company’s development team is designing a customer directory application. The application must list customers by the area code of their phone number. The area code is defined as the first three characters of the phone number.
            The main page of the application will be based on an indexed view that contains the area and phone number for all customers.
            You need to return the area code from the PhoneNumber field. Solution: You run the following Transact-SQL statement:
            70-761 dumps exhibit
            Does the solution meet the goal?

            • A. Yes
            • B. No

            Answer: A

            Explanation: The following indicates a correct solution:
            The function returns a nvarchar(10) value.
            Schemabinding is used.
            SELECT TOP 1 … gives a single value Note: nvarchar(max) is correct statement. nvarchar [ ( n | max ) ]
            Variable-length Unicode string data. n defines the string length and can be a value from 1 through 4,000. max indicates that the maximum storage size is 2^31-1 bytes (2 GB).
            References:
            https://docs.microsoft.com/en-us/sql/t-sql/data-types/nchar-and-nvarchar-transact-sql https://sqlstudies.com/2014/08/06/schemabinding-what-why/

            NEW QUESTION 11
            You need to create a table named MiscellaneousPayment that meets the following requirements:
            70-761 dumps exhibit
            Which Transact-SQL statement should you run?

            • A. CREATE TABLE MiscellaneousPayment (Id uniqueidentifier DEFAULT NEWSEQUENTIALID() PRIMARY KEY,Reason varchar(500),Amount money)
            • B. CREATE TABLE MiscellaneousPayment (Id int identify(1,1)PRIMARY KEY,Reason nvarchar(500),Amount numeric(19,4))
            • C. CREATE TABLE MiscellaneousPayment (Id uniqueidentifier DEFAULT NEWSEQUENTIALID() PRIMARY KEY,Reason varchar(500),Amount decimal(19,4))
            • D. CREATE TABLE MiscellaneousPayment (Id uniqueidentifier DEFAULT NEWID() PRIMARY KEY,Reason nvarchar(500),Amount decimal(19,4))

            Answer: D

            NEW QUESTION 12
            Note: This question is part of a series of questions that use the same or similar answer choices. An answer choice may be correct for more than one question in the series. Each question is independent of the other questions in this series. Information and details provided in a question apply only to that question.
            You have a database that is denormalized. Users make frequent changes to data in a primary table.
            You need to ensure that users cannot change the tables directly, and that changes made to the primary table also update any related tables.
            What should you implement?

            • A. the COALESCE function
            • B. a view
            • C. a table-valued function
            • D. the TRY_PARSE function
            • E. a stored procedure
            • F. the ISNULL function
            • G. a scalar function
            • H. the TRY_CONVERT function

            Answer: B

            Explanation: Using an Indexed View would allow you to keep your base data in properly normalized tables and maintain data-integrity while giving you the denormalized "view" of that data.
            References:
            http://stackoverflow.com/questions/4789091/updating-redundant-denormalized-data-automatically-in-sql-server

            NEW QUESTION 13
            Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.
            After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.
            You are creating indexes in a data warehouse.
            You have a dimension table named Table1 that has 10,000 rows. The rows are used to generate several reports. The reports join a column that is the primary key.
            The execution plan contains bookmark lookups for Table1. You discover that the reports run slower than expected.
            You need to reduce the amount of time it takes to run the reports.
            Solution: You create a nonclustered index on the primary key column that includes the bookmark lookup columns.
            Does this meet the goal?

            • A. Yes
            • B. No

            Answer: B

            NEW QUESTION 14
            Note: This question is part of a series of questions that use the same scenario. For your convenience, the scenario is repeated in each question. Each question presents a different goal and answer choices, but the text of the scenario is exactly the same in each question in this series.
            You query a database that includes two tables: Project and Task. The Project table includes the following columns:
            70-761 dumps exhibit
            70-761 dumps exhibit
            You plan to run the following query to update tasks that are not yet started:
            70-761 dumps exhibit
            You need to return the total count of tasks that are impacted by this UPDATE operation, but are not associated with a project.
            What set of Transact-SQL statements should you run?
            70-761 dumps exhibit

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

            Answer: B

            Explanation: The WHERE clause of the third line should be WHERE ProjectID IS NULL, as we want to count the tasks that are not associated with a project.

            NEW QUESTION 15
            You are building a stored procedure that will update data in a table named Table1 by using a complex query as the data source.
            You need to ensure that the SELECT statement in the stored procedure meets the following requirements:
            Data being processed must be usable in several statements in the stored procedure.
            Data being processed must contain statistics. What should you do?

            • A. Update Table1 by using a common table expression (CTE).
            • B. Insert the data into a temporary table, and then update Table1 from the temporary table.
            • C. Place the SELECT statement in a derived table, and then update Table1 by using a JOIN to the derived table.
            • D. Insert the data into a table variable, and then update Table1 from the table variable.

            Answer: B

            Explanation: Temp Tables...
            Are real materialized tables that exist in tempdb Have dedicated stats generated by the engine Can be indexed
            Can have constraints
            Persist for the life of the current CONNECTION Can be referenced by other queries or subproce

            NEW QUESTION 16
            You have a database that contains the following tables.
            70-761 dumps exhibit
            You need to create a query that returns each complaint, the names of the employees handling the complaint, and the notes on each interaction. The Complaint field must be displayed first, followed by the employee’s name and the notes. Complaints must be returned even if no interaction has occurred.
            Construct the query using the following guidelines:
            - Use two-part column names.
            - Use one-part table names.
            - Use the first letter of the table name as its alias.
            - Do not Transact-SQL functions.
            - Do not use implicit joins.
            - Do not surround object names with square brackets.
            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 the code that has been provided as well as below it.
            70-761 dumps exhibit
            70-761 dumps exhibit
            1 SELECT c.Complaint, e.Name, i.Notes 2 FROM Complaints c
            3 JOIN
            4 JOIN
            70-761 dumps exhibit

              Answer:

              Explanation: 1 SELECT c.Complaint, e.Name, i.Notes
              2 FROM Complaints c
              3 JOIN Interactions i ON c.ComplaintID = i.ComplaintID
              4 JOIN Employees e ON i.EmployeeID = E.EmployeeID

              NEW QUESTION 17
              Note: This question is part of a series of questions that use the same or similar answer choices. An answer choice may be correct for more than one question in the series. Each question is independent of the other questions in this series. Information and details provided in a question apply only to that question.
              You create a table named Customers. Data stored in the table must be exchanged between web pages and web servers by using AJAX calls that use REST endpoint.
              You need to return all customer information by using a data exchange format that is text-based and lightweight.
              Which Transact-SQL statement should you run?
              70-761 dumps exhibit
              70-761 dumps exhibit

              • A. Option A
              • B. Option B
              • C. Option C
              • D. Option D
              • E. Option E
              • F. Option F
              • G. Option G
              • H. Option H

              Answer: C

              Explanation: JSON can be used to pass AJAX updates between the client and the server.
              Export data from SQL Server as JSON, or format query results as JSON, by adding the FOR JSON clause to a SELECT statement.
              When you use the FOR JSON clause, you can specify the structure of the output explicitly, or let the structure of the SELECT statement determine the output.
              References: https://msdn.microsoft.com/en-us/library/dn921882.aspx

              P.S. Easily pass 70-761 Exam with 191 Q&As Certleader Dumps & pdf Version, Welcome to Download the Newest Certleader 70-761 Dumps: https://www.certleader.com/70-761-dumps.html (191 New Questions)