Chapter 16: Advanced Use of Functions and
lượt xem 5
download
Chapter 16: Advanced Use of Functions and Variables LPAD('o',ROUND(AVG(ReturnedDate-CheckOutDate)/2,0),'o') AS Graph from BOOKSHELF_CHECKOUT group by Name order by AVG(ReturnedDate-CheckOutDate); Day 1 2 3 4 5 6 7 ....0....0....0....0....0....0....0 ----------------------------------ooooooo ooooooo ooooooooo ooooooooo oooooooooo oooooooooooo oooooooooooooooooooooooooo 299 NAME DAYSOUT ---------------- ------DORAH TALBOT 13 EMILY TALBOT 14 JED HOPKINS 18 GERHARDT KENTGEN 19 PAT LAVAY 21 FRED FULLER 24 ROLAND BRANDT 52 7 rows selected. This use of LPAD is similar to what was done in Chapter 13, where the cows and bulls were shown in their family tree. Basically, a lowercase o is the column here, and it is padded on the left with a...
Bình luận(0) Đăng nhập để gửi bình luận!
CÓ THỂ BẠN MUỐN DOWNLOAD