我想加快在餐饮公司的工作。我有一个包含所有产品所有成分的Excel文件。
例如:
https://docs.google.com/spreadsheets/d/1-AFHpl8aoIiMXz2RE1Xv7JcI7pCIMQfMoq-lQJBx5Gw/edit?usp=sharing
答案 0 :(得分:1)
=ARRAYFORMULA(TRIM(SPLIT(TRANSPOSE(SPLIT(TRANSPOSE(QUERY(TRANSPOSE(QUERY(TRANSPOSE(
IF(master!E3:Z<>"", master!A3:A&"♦"&master!B3:B&"♦"&master!E1:1&"♦"&master!E3:Z&"♠", ))
, , 500000)), , 500000)), "♠")), "♦")))
=ARRAYFORMULA(QUERY({C2:C,VALUE(D2:D)},
"select Col1,sum(Col2)
where Col1<>''
group by Col1
order by Col1
label sum(Col2)'Total',Col1'Shopping List'"))
答案 1 :(得分:0)
以下公式适用于一种配方:
=TRANSPOSE(FILTER({E1:K1;QUERY(A1:K5,"SELECT E,F,G,H,I,J,K WHERE A='"&H25&"'", FALSE)}, NOT(ISBLANK(QUERY(A1:K5,"SELECT E,F,G,H,I,J,K WHERE A='"&H25&"'", FALSE)))))
(我以I25单元为例)。