Which of the following properties will you configure in order to accomplish the

Which of the following properties will you configure

This preview shows page 6 - 8 out of 13 pages.

Which of the following properties will you configure in order to accomplish the task? A. Show B. Or C. Sort D. Criteria Answer: C Explanation: In order to accomplish the task, you should configure the Sort property. This property displays the extracted data in a specific order. The Sort property sets the data inascending or descending order. Answer A is incorrect. The Show property is used to include a field in the query. Answer D is incorrect. The Criteria property defines various specifications for the query. Answer B is incorrect. The Or property defines the optional entries that create ORelements of the selection criteria of the query. QUESTION: 128 James works as a Database Designer for AccessSoft Inc. The company has a Windows Vista computer, which has a database named Orders. The database 92
Background image
contains a table named OrderDetails. Users run queries against the database to placeorders of customers. They also retrieve data related to the processing of orders and information about the customers who place orders. Users complain that the retrieval of data is very slow. James opens the following query: SELECT * FROM OrderDetails; What should he do to enhance the performance of the query? A. Use the WHERE clause with the SELECT statement. B. Use the GROUP BY clause with the SELECT statement. C. Use the DISTINCT clause with the SELECT statement. D. Use the TOP clause with the SELECT statement. Answer: A Explanation: In order to enhance the performance of the query, James will use the WHERE clause with the SELECT statement as follows: SELECT * FROM OrderDetails WHERE custname='customer name'; The WHERE clause is used to filter data given in the table. The filter is based on one or more columns given after the SELECT statement. The columns are separated by commas. Answer C is incorrect. The DISTINCT clause is used to prevent rows from getting duplicated in the result set. It can only be used with the SQL SELECT statement. The syntax for the DISTINCT clause is as follows: SELECT DISTINCT <columns> FROM <table_name> WHERE <conditions> Answer D is incorrect. The TOP clause is used to retrieve data for the first set of rows. The example is as follows: SELECT * TOP 10 FROM OrderDetails; The statement will retrieve only the top ten rows from the OrderDetails table. Answer B is incorrect. The GROUP BY clause groups selected rows on the basis of values of specified column(s) for each row, and returns a single row of summary information for each group. Rows that have the same values in the specified grouping column(s) are grouped together. The GROUP BY clause suppresses duplicate rows for the grouping column(s). It does not guarantee the order of the result set. Therefore, an ORDER BY clause should be used with the GROUP BY clause to sort the result set in the desired order.
Background image
Image of page 8

You've reached the end of your free preview.

Want to read all 13 pages?

  • Fall '20
  • Foreign key, Microsoft Office 2007

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture