如何从包含大量段落文本的数据库列中搜索50%到80%。 [英] How to search 50% to 80% from a database column which has contained lots of paragraph text.
本文介绍了如何从包含大量段落文本的数据库列中搜索50%到80%。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想从数据库列中搜索50%到80%的类似文本。
该特定列的行包含许多段落文本。从这个文本
我需要找出哪一行在该特定列中有相似的文字。
如果需要,则使用函数。
I want to search 50% to 80% similar text from a database column.
The rows of that particular column has contained lots of paragraph text. From this text
I need to find out which are all the rows has similar text in that particular column.
If required, then use function.
推荐答案
不要在SQL中执行。
SQL字符串处理是 - 充其量 - 非常基本。
你想要做的事情非常复杂。
说真的:这对你的目的来说太过分了,可能,但是它是您要求的高级形式: Levenshtein编辑距离算法 [ ^ ]
使用真正的编程语言执行此操作,无论哪种语言。 SQL是一个糟糕的选择。
Don't do it in SQL.
SQL string handling is - at best - pretty basic.
And what you want to do is pretty complicated.
Seriously: This is overkill for your purposes, probably, but it's an advanced form of what you are asking for: Levenshtein Edit Distance Algorithm[^]
Do this in your "real" programming language, whichever that is. SQL is a poor choice.
是的,OriginalGriff是对的,但您可能想了解更多关于文本相似度算法的信息。
请按照以下链接:
模式匹配:格式塔方法 [ ^ ]
Simil:寻找类似字符串的算法 [ ^ ]
文本相似度算法 - 解决方案2 [ ^ ]
Yes, OriginalGriff is right, but you may want to know a bit more about text similarity algorithms.
Please, follow below links:
Pattern Matching: the Gestalt Approach[^]
Simil: An algorithm to look for similar strings[^]
Text similarity algorithm - solution 2[^]
这篇关于如何从包含大量段落文本的数据库列中搜索50%到80%。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文