sql - How to count occurrence of each sentence in Excel in this specific case?
问题描述
The challenge here is the sentence is not split by cell. They are in the same column, but they might appear in the same cell. One sentence per line.
I need to count the occurrence of each sentence, for example, occurrence of "The cat is pink" is 2 and occurrence of "The dog is green" is 1.
I can also do Access 2016 if needed.
解决方案
(假设您可以将多句单元格拆分为多个单元格)
1)用多个句子拆分单元格,您应该能够调整此代码来执行此操作。
2) 制作该列的副本(在同一张纸或另一张纸上的其他地方——在同一张纸上使用 B 列),
3)删除复制列的重复值
4)在列旁边使用以下数组公式:
{=SUM(LEN(A$1:A$5)-LEN(SUBSTITUTE(A$1:A$5,B1,"")))/LEN(B1)}
<CTRL><SHIFT><ENTER>
(输入数组公式时按下)
推荐阅读
- python - Python:有没有办法在不使用“setrecursionlimit”的情况下腌制高度递归的对象?
- wso2 - WSO2 EI - 错误 - java.sql.SQLException: ORA-01483: DATE 或 NUMBER 绑定变量的长度无效
- macos - Heroku cli (brew install heroku): ArgumentError: user emixam23 doesn't exist
- python-3.x - 如何在“pytest.dependency”中使用测试数据/外部变量?
- ansible - Ansible playbook,临时变量无法在两台主机之间使用
- aws-lambda - 具有相同 lambda 的多队列处理的长轮询与短轮询 SQS
- java - 使用Java中的输入流提取特定路径下的Json嵌套对象
- java - 使用构建器模式自动执行以下 REST API 发布请求(下面的有效负载) - 无法仅设置列表的第一个元素
- python - Python3 如何处理 subprocess.run 输出中返回的特殊字符?
- python - 在 Python 的 while 循环中调用一个函数,并将其先前的返回值作为参数