简体   繁体   English

如何根据另一列中的最新唯一日期获取单元格的值?

[英]How to get value of a cell based on latest unique date in another column?

I have a table of data which tracks all my expenses.我有一张数据表,可以跟踪我的所有费用。 There are 3 main columns mainly Date, Balance and Profit.有 3 个主要列,主要是日期、余额和利润。

I would like to output the data into another table which automatically lists out my latest balance for that day.我想将 output 的数据放入另一个表中,该表会自动列出我当天的最新余额。 I tried to google but came up with nothing.我试图谷歌但一无所获。 Hopefully someone helps me out on this!希望有人能帮助我解决这个问题! Thanks alot!非常感谢!

Cell F3 should display 1290 and F4 should display 1818.单元格 F3 应显示 1290,F4 应显示 1818。

在此处输入图像描述

For the Daily tracking on column E, i used the formula: =Arrayformula(unique(A3:A))对于 E 列的每日跟踪,我使用了公式:=Arrayformula(unique(A3:A))

Without a helper column没有辅助列

Please also try the following formula.也请尝试以下公式。

=QUERY(ARRAYFORMULA(IF(A2:A=A3:A,,{A2:A,B2:B,C2:C})), "where Col1 is not null")

For a different locale you can use the following version:对于不同的语言环境,您可以使用以下版本:

=QUERY(ARRAYFORMULA(IF(A2:A=A3:A;;{A2:A\B2:B\C2:C})); 
        "where Col1 is not null")

在此处输入图像描述

Functions used:使用的功能:

I think you need to use one more column to get the last row of date, so on "D3" put =ARRAY_CONSTRAIN(ARRAYFORMULA(IF(A3:A=A4:A,,A3:A)),COUNTA(A3:A),1) to get the last row of date我认为您需要再使用一列来获取日期的最后一行,所以在“D3”上放=ARRAY_CONSTRAIN(ARRAYFORMULA(IF(A3:A=A4:A,,A3:A)),COUNTA(A3:A),1)获取最后一行日期

then on "E3" put =Arrayformula(FILTER({D3:D,B3:C},ISBLANK(D3:D)=FALSE)) as you were using unique() , let use filter() instead然后在 "E3" 上放=Arrayformula(FILTER({D3:D,B3:C},ISBLANK(D3:D)=FALSE)) ,因为你正在使用unique() ,让我们使用filter()代替

我希望它会有所帮助 It should have more other ways to get this worked, I think this is the easiest solution in my opinion它应该有更多其他方法来完成这项工作,我认为这是我认为最简单的解决方案

by the way if you still don't understand you can ask me more顺便说一句,如果你还是不明白,你可以问我更多

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何基于另一个列中的唯一值获取Excel列的值 - How to grab the value of an excel column based on a unique value in another column 如何根据另一列中的值替换单元格值以进行状态更新? - How to replace cell value based on a value in another column for status update? 如何根据另一列中的重复项修改列并在 Excel 中保留唯一值 - How to amend a column based on duplicates in another and leave a unique value in Excel 基于另一个单元格获取单元格中的值 - get value in a cell based on another cell 根据另一列中的单元格值验证一列中的单元格值 - Validate cell value in one column based on cell value in another column 如何根据 excel 中另一列百分比值的完成百分比为单元格着色? - How to color a cell based on % of completion of another column % value in excel? 如何使用公式或VBA根据来自另一列的另一个单元格值来设置单元格中的值? - How to set value in a cell based on another cell value from another column using formula or VBA? 基于另一张纸上的值(日期)的颜色单元格 - colour cell based on value (date) on another sheet 根据另一个给定值的最新日期获取值 - Getting a value based on the latest date for another given value 如何使用VLOOKUP获取基于另一个列值的列值? - How to use a VLOOKUP to get a column value based on another column value?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM