substring和substr有什么区别

如题所述

他们的区别是:
substring意思是子链。
substr指的是字符函数。

例句比较:
substring
1、This is the substring after the character? in the URL.
即URL中字符?之后的子字符串。
2、A substring is zero or more contiguous string length units of input string.

子字符串是输入字符串的零个或多个相邻字符串长度单元。。
3、In Figure 5, the substring of length 1 from the first byte of the string has been specified.
在图5中,已经指定字符串第一个字节的长度为1的子字符串。

substr
1、This explains the use of substr ( text, match [0], match [ 1]) in the last line of code.
这解释了最后一行代码中字符函数(text,match[0],match[1])的使用。
2、Length of a string variable: Input argument for the SUBSTR function, whichdetermines the desired length of the resulting string or output of the LENGTHfunction.

字符串变量的长度:字符函数的输入参数,决定了结果字符串的期望长度或LENGTH函数的输出。
3、User define function REGEXP_SUBSTR.

用户定义的函数REGEXP SUBSTR。
温馨提示:答案为网友推荐,仅供参考
相似回答