跳到主要内容

如何在Microsoft Excel中对动态数据进行排序?

假设您正在Excel中管理固定商店的存储数据,并且需要在存储数据发生更改时自动对其进行排序。 如何在Excel中自动对动态存储数据进行排序? 本文将向您展示一种巧妙的方式来对Excel中的动态数据进行排序,并在原始数据一次更改时自动保持排序更新。

使用公式对Excel中的综合数据进行排序


使用公式对Excel中的综合数据进行排序

1.在原始数据的开头插入一个新列。 在这里,我在原始数据之前插入列号,如下图所示:

2.按照我们的示例,输入公式 = RANK(C2,C $ 2:C $ 6) 在单元格A2中按存储的原始产品进行排序,然后按 输入 键。

3.继续选择单元格A2,拖动 填充手柄 向下到单元格A6,以获取“编号”列中的所有其余编号。

4:复制原始数据的标题,然后将其粘贴到原始表旁边,例如E1:G1。 在“所需编号”列中,插入与编号顺序相同的序列号,例如1、2…。 看截图:

5.输入公式 = VLOOKUP(E2,A $ 2:C $ 6,2,FALSE) 进入单元格F2,然后按 输入 键。

此公式将查找所需NO的值。 在原始表格中,并在单元格中显示相应的产品名称。

备注:如果在“产品”列或“存储”列中显示重复或平局,则最好应用此功能 =IFERROR(VLOOKUP(E2,A$2:C$6,2,FALSE), VLOOKUP(E2,A$2:C$6,2,TRUE))

6.继续选择单元格F2,将填充手柄向下拖动到单元格F6以获取所有产品名称,并继续选择范围F2:F6,向右拖动填充手柄至范围G2:G6以获取所有存储号。

然后,您将获得一个新的存储表,按存储顺序降序排列,如下图所示:

假设您的固定商店再购买145支笔,现在您总共有200支笔。 只需修改笔存储的原始表,您就会在眨眼间看到新表已更新,请参见以下屏幕截图:

最佳办公生产力工具

🤖 Kutools 人工智能助手:基于以下内容彻底改变数据分析: 智能执行   |  生成代码  |  创建自定义公式  |  分析数据并生成图表  |  调用 Kutools 函数...
热门特色: 查找、突出显示或识别重复项   |  删除空白行   |  合并列或单元格而不丢失数据   |   不使用公式进行四舍五入 ...
超级查询: 多条件VLookup    多值VLookup  |   跨多个工作表的 VLookup   |   模糊查询 ....
高级下拉列表: 快速创建下拉列表   |  依赖下拉列表   |  多选下拉列表 ....
列管理器: 添加特定数量的列  |  移动列  |  切换隐藏列的可见性状态  |  比较范围和列 ...
特色功能: 网格焦点   |  设计图   |   大方程式酒吧    工作簿和工作表管理器   |  资源库 (自动文本)   |  日期选择器   |  合并工作表   |  加密/解密单元格    按列表发送电子邮件   |  超级筛选   |   特殊过滤器 (过滤粗体/斜体/删除线...)...
前 15 个工具集12 文本 工具 (添加文本, 删除字符,...)   |   50+ 图表 类型 (甘特图,...)   |   40+ 实用 公式 (根据生日计算年龄,...)   |   19 插入 工具 (插入二维码, 从路径插入图片,...)   |   12 转化 工具 (小写金额转大写, 货币兑换,...)   |   7 合并与拆分 工具 (高级组合行, 分裂细胞,...)   |   ... 和更多

使用 Kutools for Excel 增强您的 Excel 技能,体验前所未有的效率。 Kutools for Excel 提供了 300 多种高级功能来提高生产力并节省时间。  单击此处获取您最需要的功能...

产品描述


Office Tab 为 Office 带来选项卡式界面,让您的工作更加轻松

  • 在Word,Excel,PowerPoint中启用选项卡式编辑和阅读,发布者,Access,Visio和Project。
  • 在同一窗口的新选项卡中而不是在新窗口中打开并创建多个文档。
  • 每天将您的工作效率提高50%,并减少数百次鼠标单击!
Comments (49)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
hi,, what if there will be more than to numbers that were ties?
This comment was minimized by the moderator on the site
Wonderful....Thanks this helped me
This comment was minimized by the moderator on the site
I had lost the ability to sort several rows of information on one page of a spreadsheet with many pages. After trying to fix the situation by reworking formulas none of the information will sort now. Can I fix this without having to recreate page that is the problem. Same information needs to be transferred to another page that contains all information from all the pages; this too stops sort there. Big problem and don't know how to solve it.
This comment was minimized by the moderator on the site
i need to convert a number into another format.lets take an example - no =12394567 i need to convert it into 674501239. its simple (last 2 digit in first ,then 2nd last 2 digits then add a zero(0) then first four digits in the last. can you please guys tell me the formula for this?
This comment was minimized by the moderator on the site
=CONCATENATE(RIGHT(A1,2),MID(A1,5,2),"0",LEFT(A1,4)) will get you that order of digits.
This comment was minimized by the moderator on the site
you can use the CONCATENATE and then LEFT or RIGHT in excel formula. Its easy, Got it ?
This comment was minimized by the moderator on the site
Sure, mail me the detail and I will show you the finished product
This comment was minimized by the moderator on the site
Hi, no problem, email me and I will show hulu how the finished product works.
This comment was minimized by the moderator on the site
Hi Dear, I have a sheet with 100 items , each item has a specific cost that happens in one year .I want to create another sheet that shows only the item that has cost in one year automatically ? for example all of the item with item No. and description and cost in 2016 and then for 2017 and so on... thanks
This comment was minimized by the moderator on the site
how can i sort lowest to highest value (a to z) in your example i.e lowest storage to highest storage. i use your formulla '=RANK(C2,C$2:C $6) + COUNTIF(C$2:C2, "="&C2)-1'" & "=IFERROR(VLOOKUP(E2,A$2:C$6,2,FALSE), VLOOKUP(E2,A$2:C$6,2,TRUE))" . al is going well but i cannot sort lowest to highest.
This comment was minimized by the moderator on the site
Kedirech, you rock!! The COUNT thing eliminates ties!! I've had this problem for years but now this is the solution!! Thanks!!
This comment was minimized by the moderator on the site
Hi, I do it with if statements alone, how do I let you look at my file?
There are no comments posted here yet
Load More
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations