1. 案例定位

用原書銷售資料示範格式修復、乘法計算與條件式日期公式。

2. 學習目標

能以 Copilot 描述計算需求,再由 Excel 建立並驗證可重算欄位。

3. 案例情境

匯出的 sales data 失去部分格式。原書先把單價改成貨幣,再新增 total_purchase_amt 與 Wty_Expiration。

4. 開始資料

customer_id purchase_date product_name per_prod_amt qty
1 01/17/21 Product A 274.53 71
2 04/26/21 Product B 9,856.09 59
3 04/07/21 Product B 8,353.45 72

原書規則:Product A 保固 3 年、Product B 2 年、Product C 1 年;貨幣顯示 2 位小數。

5. 分析方法

total_purchase_amt = per_prod_amt × qty。保固到期日依產品類別,在 purchase_date 分別加 36、24、12 個月。Copilot 可產生公式,但 Excel 負責實際計算。

6. 計算結果

customer_id total_purchase_amt Wty_Expiration
1 19,491.63 01/17/24
2 581,509.31 04/26/23
3 601,448.40 04/07/23

7. 結果分析與管理解讀

這類任務很適合讓 Copilot協助產生 formula proposal,但高金額結果必須以 Excel 儲存格公式重新計算並抽查,避免語言模型數字錯誤。

8. 人工智慧提問詞

在不改動原始欄位的前提下,新增 total_purchase_amt = per_prod_amt × qty,貨幣 2 位小數;再依 Product A=3 年、B=2 年、C=1 年建立 Wty_Expiration。先顯示公式邏輯,再讓 Excel 套用。

9. 思考/假設情境

問題: customer_id 1 的 qty 從 71 改成 80,總購買金額是多少?

參考解答: 274.53 × 80 = 21,962.40。