排序与筛选解决什么问题What Sorting & Filtering Solve

排序是把行按某一列的值重新排列(升序/降序);筛选是只保留满足条件的行、隐藏其余。两者都是数据整理的第一步:先排序便于浏览趋势,先筛选便于聚焦目标数据。

Sorting reorders rows by a column's values (ascending/descending); filtering keeps only rows that meet a condition. Both are the first step in data prep: sort to see trends, filter to focus on target data.

用 Excel / Google Sheets 排序筛选Sort & Filter in Excel / Sheets

  • 选中数据区域(含表头),点击「数据 → 排序」,选择依据列与升/降序。
  • 筛选:点击「数据 → 筛选」,每列表头出现下拉箭头,可设条件(等于、包含、大于…)。
  • 记得勾选"数据包含标题",否则表头会被当成数据一起排序。
  • Select the data range (with header), click Data → Sort, choose the column and order.
  • Filter: Data → Filter, then use the dropdown on each header to set conditions (equals, contains, greater than…).
  • Tick "My data has headers" so the header isn't sorted as a row.

三个常见坑Three Common Pitfalls

1. 数字被当成文本排序1. Numbers sorted as text

"10" 排在 "2" 前面,是因为列被识别成文本。先确保该列是数值格式,或用 365Lab 工具的"数字规范化"再排序。

"10" appears before "2" because the column is text. Make it a number type first, or normalize with 365Lab's number tool before sorting.

2. 只排了一列,其余错位2. Only one column sorted, rest misaligned

排序时一定要选中"整行",否则只有某一列重排,其他列不动,数据就乱套了。

Always sort the whole row; sorting a single column alone misaligns the rest of the data.

3. 筛选后复制漏了隐藏行3. Copying after filter misses hidden rows

筛选后直接复制会带出隐藏行。正确做法是用"可见单元格"复制,或先把筛选结果导出为新 CSV。

Copying right after a filter can include hidden rows. Use "visible cells only", or export the filtered result to a new CSV.

提示:想要不打开 Excel 也能排序筛选?用 365Lab 在线 CSV 工具,按列排序、按条件筛选、去重一步到位,且数据全程本地处理不上传。
Tip: Want to sort/filter without Excel? Use the 365Lab online CSV toolkit to sort by column, filter by condition and dedupe — all locally, no upload.

命令行方式(进阶)Command Line (Advanced)

在终端里,sort -t, -k2 -n file.csv 可按第 2 列数值排序;配合 awk 可实现复杂筛选。适合大文件和自动化脚本。

In the terminal, sort -t, -k2 -n file.csv sorts by column 2 numerically; combine with awk for complex filters. Great for large files and automation.

想马上试试?打开在线工具,拖入 CSV 即可按列排序、按条件筛选并导出。

Want to try now? Open the toolkit, drop in your CSV to sort by column, filter by condition and export.

打开 CSV 清洗工具 →Open the CSV Cleaner →