Question 96

You have a dataset named 'SALES' with variables 'ORDER D', 'PRODUCT ID', 'SALES DATE', 'QUANTITY, 'PRICE', 'DISCOUNT'. You want to create a new dataset named 'SALES SUMMARY' that contains only the orders placed in the month of January 2023, and includes the variables 'ORDER ID', 'PRODUCT ID', and 'TOTAL VALUE'. The 'TOTAL VALUE' is calculated as 'QUANTITY ' PRICE ' (1 - DISCOUNT)'. Which of the following DATA step code snippets would achieve this?
  • Question 97

    You have a SAS dataset named 'CustomerData' with variables 'CustomerlD', 'OrderDate', and 'Order Total'. You want to create a report that shows the total order amount for each customer who placed an order in the year 2022. The dataset is sorted by 'CustomerlD' and then by 'OrderDate'. Which of the following code snippets would correctly generate the report using PROC SQL?
  • Question 98

    Given the data set NAMES:

    Which PROC SORT program creates the NAMES data set shown below?
  • Question 99

    You have two SAS data sets, 'SALES' and 'ORDERS', both stored in the same library named 'SALES DATA. You need to combine the data from these two data sets into a new data set called 'SALES ORDERS' using the 'SET' statement. Which of the following statements will correctly combine the data from both 'SALES' and 'ORDERS' data sets into the new data set?
  • Question 100

    Given the input data set WORK.RUN:

    Given the following DATA step:

    What is the correct output data set WORK.RUN2?