substring_index(str,delim,count)
函数说明
str:要处理的字符串
delim:分隔符
count:计数
例子:str = aaaa,bbb
substring_index(str,',',1) = aaa
substring_index(str,',',2) = aaa,bbb
count如果为正,从左往右取count个
count如果为正,从右往左取count个
substring_index(str,delim,count)
函数说明
str:要处理的字符串
delim:分隔符
count:计数
例子:str = aaaa,bbb
substring_index(str,',',1) = aaa
substring_index(str,',',2) = aaa,bbb
count如果为正,从左往右取count个
count如果为正,从右往左取count个
本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。