TAILIEUCHUNG - Oracle SQL Plus The Definitive Guide- P13

Oracle SQL Plus The Definitive Guide- P13:Every day, computer professionals the world over wake up, travel to the office, sit down in front of a computer, and begin another day working with that database called Oracle. Programmers write queries and stored procedures. Database administrators monitor performance, make database changes, and perform other maintenance tasks. Operations people may need to back up or recover a database. | previous page page_97 next page Page 97 FROM EMPLOYEE E PROJECT P PROJECT_HOURS PH WHERE AND ORDER BY Printing data in a page footer You can print data as part of the page footer using the same method just shown for the page header. The only difference is that you would normally use the OLD_VALUE clause with the COLUMN command rather than NEW_VALUE. That s because when SQL Plus prints the footer it has already read the next detail record from the database. Using NEW_VALUE for data in the footer would cause the footer to display information pertaining to the next page in the reportnot something you would normally want to happen. Totals and Subtotals SQL Plus allows you to print totals and subtotals in a report. To do this you use a combination of the BREAK command and one or more COMPUTE commands. This section continues where the previous section left off. It will show you how to modify the master detail report created earlier so that it totals the hours and dollars by project and by employee. You will also see how to print grand totals for these columns at the end of the report. The COMPUTE Command The COMPUTE command defines summary calculations needed in a report. You can use COMPUTE in conjunction with BREAK to calculate and print column totals averages minimum and maximum values and so on. These calculations are performed by SQL Plus as the report runs. Syntax of the COMPUTE command The syntax for the COMPUTE command looks like this COMP UTE AVG COU NT MAX IUM MIN IMUM NUM BER STD SUM VAR IANCE . LABEL label_text OF column_name. ON group_column_name ROW REPORT . where COMP UTE May be abbreviated to COMP. Entering COMPUTE with no parameters causes SQL Plus to list all currently defined computations. previous page page_97 next page previous page page_98 next page Page 98 AVG Computes the average of all non-null values for a column. AVG only applies to columns of .

TỪ KHÓA LIÊN QUAN
TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.