在excel中删除重复(有条件) [英] Removing duplicates (with condition) in excel

查看:205
本文介绍了在excel中删除重复(有条件)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一张由3列和数千行组成的表格。
列是First-Name,Last-Name和E-Mail。
并不是所有的条目(行)都有电子邮件列中的数据 - 一些它只是空的。
工作表包含重复,这意味着两行具有相同的名字和相同的姓氏。
我想以以下方式删除重复项:
如果其中一个重复条目具有电子邮件地址,请删除另一个。
如果两者都有电子邮件地址,请删除其中的一个(例如,首先说,例如)。
如果两者都没有电子邮件,则相同。



我该怎么办? (当然,手动做不是一个选择)。



谢谢。

解决方案

通过电子邮件地址排序范围。

删除第1列中的重复(全选3,但告诉excel使用ony cols 1和2取消重复)

将此记录为宏,以查看excel如何与VBA执行此操作


I have a sheet that consists of 3 columns and thousands of rows. The columns are First-Name, Last-Name, and E-Mail. not all of the entries (rows) have data in the E-Mail column - for some it's just left empty. The sheet contains "duplicates", which means two rows with both the same First name, and the same last name. I'd like to remove the duplicates in the following manner: If one of the duplicate entries has E-Mail address, remove the other. If both have E-Mail address, remove one of them (whichever one. say first, for example). And the same if both don't have E-Mail.

How can I do this task? (of-course, doing it manually is not an option).

Thanks.

解决方案

sort range by email address.
remove duplicates on the 1st 2 columns (elect all 3, but tell excel to use ony cols 1 & 2 to de-duplicate)
record this as a macro to see how excel does this with VBA

这篇关于在excel中删除重复(有条件)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆