如何在Oracle表中搜索换行符? [英] How to search new line char in oracle table?
本文介绍了如何在Oracle表中搜索换行符?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个从数据库返回的数据(以字节格式)创建的文件的问题.
问题是文件中有一些换行符.
我想知道是否可以编写where子句来检查某些记录是否具有换行符吗?
I have an issue with a file that's created from data (in format of bytes) returned from the database.
the problem is that there is a few newlines in the file.
i would like to know if there is a way to write a where clause to check if some record has a newline character?
推荐答案
使用CHR函数查找ASCII值:
Using the CHR function to look for the ASCII value:
select *
from your_table
where instr(your_text_col, chr(10)) > 0;
如果要搜索回车,则为chr(13).
If you want to search for carriage returns, that would be chr(13).
这篇关于如何在Oracle表中搜索换行符?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文