THẢO LUẬN

@tuana9a thanks bác

0

đây là 1 cái link ,ấn vào đăng ký tài khoản phải cần có mã mời anh có thể bớt chút tg xem dùm em đc ko ạ zl em 0968102462

0

Thi thoảng mình vào clear hết image của docker, vừa dọn dc cả những image outdate lâu ngày ko dùng, trống dc nhiều.

0
Avatar
đã bình luận cho bài viết
thg 12 15, 2023 7:11 SA

SELECT p.productCode, p.productName, (p.MSRP-p.buyPrice) * od.quantityOrdered AS Profit_1, (od.priceEach-p.buyPrice) * od.quantityOrdered AS Profit_2, (SELECT (Profit_1 - Profit_2)) AS Different, (SELECT IF(SUBSTR(p.productName, 1, 4) < 1940, 'Group 1', 'Group 2')) AS Group_ FROM classicmodels.products p JOIN classicmodels.orderdetails od ON od.productCode = p.productCode GROUP BY p.productCode ORDER BY Different DESC;

0
Avatar
đã bình luận cho bài viết
thg 12 15, 2023 6:59 SA

@1337willows đã fix

0
Avatar
đã bình luận cho bài viết
thg 12 15, 2023 6:55 SA

@1337willows đã fix

0
Avatar
đã bình luận cho bài viết
thg 12 15, 2023 6:51 SA

SELECT pl.productLine, pl.textDescription, sum(od.quantityOrdered) + ( SELECT sum(quantityInStock) FROM classicmodels.products WHERE productLine = pl.productLine) AS total_quantity_of_products FROM classicmodels.orderdetails od JOIN classicmodels.products p ON od.productCode = p.productCode JOIN classicmodels.productlines pl on p.productLine = pl.productLine GROUP BY pl.productLine HAVING total_quantity_of_products > 60000 ORDER BY total_quantity_of_products DESC;

0
Avatar
đã bình luận cho bài viết
thg 12 15, 2023 6:47 SA

@nguyenthanhnamtb2002 looix syntax

0
Avatar
đã bình luận cho bài viết
thg 12 15, 2023 6:41 SA

@nguyenthanhnamtb2002 thiếu 2004

0
Avatar
đã bình luận cho bài viết
thg 12 15, 2023 6:39 SA

select c.* , (select sum(od.quantityOrdered*od.priceEach) from classicmodels.orders o join classicmodels.orderdetails od on o.orderNumber = od.orderNumber where o.customerNumber = c.customerNumber) as total_ordered, (select sum(p.amount) from classicmodels.payments p where p.customerNumber = c.customerNumber) as total_payment, (select total_ordered - total_payment) as total_debt, (SELECT total_debt/total_ordered) AS debt_purchase_ratio from classicmodels.customers c group by c.customerName HAVING debt_purchase_ratio >= 0.3;

0
Avatar
đã bình luận câu trả lời trong câu hỏi
thg 12 15, 2023 6:35 SA

@TanLm thứ nhất là người thứ 5 nếu muốn sống thì đoán 1 trong 2 số 4 và 5, 50% sống hoặc chết chứ k chắc chắn sống. Thứ 2 là muốn chắc chắn cứu đc nhiều người nhất, nên người thứ 5 hy sinh để 4 người còn lại sống thôi. Đây là case 5 người, chứ case 100 hay 1000 người cũng vậy, hy sinh 1 người để 99 hoặc 999 người còn lại sống.

0
Avatar
đã bình luận cho bài viết
thg 12 15, 2023 6:31 SA

SELECT pl.*, COUNT(o.orderNumber) AS total_cancellation FROM classicmodels.orders o JOIN classicmodels.orderdetails od ON od.orderNumber = o.orderNumber JOIN classicmodels.products p ON p.productCode = od.productCode JOIN classicmodels.productlines pl ON pl.productLine = p.productLine WHERE o.status = 'Cancelled' AND o.orderDate BETWEEN '2004-01-01' AND '2004-12-31' GROUP BY pl.productLine ORDER BY total_cancellation DESC LIMIT 3;

0

Tks e, mục tiêu của a là cố gắng truyền tải để mọi người dễ hiểu nhất có thể 😁. Những bài khác có phần nào khó hiểu em có thể comment nha

0

@longcb dạ cảm ơn a (với nginx-ingress thì còn phải tự describe port trong cấu hình service trên rancher như sau) phần này a làm trong file nào ạ, a hướng dẫn giúp em với ạ

0
thg 12 14, 2023 5:33 CH

Cảm ơn anh đã chia sẻ

0
Avatar
đã bình luận cho bài viết
thg 12 14, 2023 4:06 CH

minh cung thay vay

0
Avatar
đã bình luận cho bài viết
thg 12 14, 2023 3:59 CH

Bài viết hay quá

0
thg 12 14, 2023 1:13 CH

@zzz anh có thể giúp đỡ em đc ko ạ

0
Viblo
Hãy đăng ký một tài khoản Viblo để nhận được nhiều bài viết thú vị hơn.
Đăng kí