1 00:00:00,910 --> 00:00:04,590 Here, we've got the average order value per user. 2 00:00:04,590 --> 00:00:08,420 What if we wanted to display more statistics for us, or for 3 00:00:08,420 --> 00:00:10,550 someone else to analyze? 4 00:00:10,550 --> 00:00:15,320 For example, you might want to find a record with the largest value, like 5 00:00:15,320 --> 00:00:20,860 the most expensive item in the store, or the highest paid employee in the company. 6 00:00:20,860 --> 00:00:27,550 Let's use another common set of functions to get the maximum and minimum values. 7 00:00:27,550 --> 00:00:33,590 We can use the max and the min functions to find the maximum and minimum values. 8 00:00:33,590 --> 00:00:35,270 It works just like average. 9 00:00:36,550 --> 00:00:40,483 Let's add these two functions to our select statement. 10 00:00:40,483 --> 00:00:50,112 First, MAX(cost) AS Maximum, 11 00:00:50,112 --> 00:00:59,353 then MIN(cost) AS Minimum. 12 00:01:00,870 --> 00:01:08,220 Look at the column in the average, maximum, and minimum functions. 13 00:01:08,220 --> 00:01:12,470 Notice that how each of the functions use the same column. 14 00:01:12,470 --> 00:01:14,051 That's something you can do. 15 00:01:14,051 --> 00:01:17,717 You can include as many functions of printing on the same 16 00:01:17,717 --> 00:01:21,440 column as many times as you like on any query. 17 00:01:21,440 --> 00:01:25,852 This enables you to generate more compelling reports in a single query 18 00:01:25,852 --> 00:01:30,201 without running multiple queries to get each piece of information. 19 00:01:35,662 --> 00:01:37,600 Also, don't forget your commas. 20 00:01:40,280 --> 00:01:45,350 These numeric functions are powerful tools, and simple to use. 21 00:01:45,350 --> 00:01:46,000 You can use them, 22 00:01:46,000 --> 00:01:50,460 not only for currency related queries, but things such as user ratings. 23 00:01:51,560 --> 00:01:55,860 You can get average reviews for movies in a movie database. 24 00:01:55,860 --> 00:02:00,570 You can count each of the reviews by the value given like on Amazon. 25 00:02:00,570 --> 00:02:03,270 Showing the customer's distribution of ratings 26 00:02:03,270 --> 00:02:07,260 helps inform the customer on whether or not they should make a purchase.