mysql - 通过 CRATE 在 MYSQL 中拆分字符串
问题描述
我想在 CRATE 中拆分一个字符串。我尝试使用 substr,但它只需要 substr(string,long,long)。我想要一个可以接受分隔符字符串的函数。
例子 :
值=1234-5656
从 XYZ 中选择 SUBSTR(value, '-',1) 作为第一个;
I want to split the value into 1234 and 5656 in a SQL query. But CRATE does not support SUBSTR(value, '-',1). So I am looking for an option to split the value in the CRATE query.
Any help?
解决方案
推荐阅读
- python - 熊猫操纵合并的 DF 以解决聚合问题
- spring-boot - 如何从自定义 Webclient Builder 获取 webflux webClient 指标
- xamarin.forms - 仍然收到 ITMS-90809:使用 --optimize=force-rejected-types-removal 后已弃用的 API 使用
- reactjs - 如何让我部署的 Web 应用程序找到我的静态文件?
- programming-languages - 寻找跨平台语言
- python - 哪个数据库可以容纳一种类型的数据的巨大列表?
- python-3.x - 找不到任何pip2,要使用pip。pip 需要安装
- javascript - 如何知道数组中的最后一个对象?角度(角度材料选项卡)
- python - 在 QProcess 中设置不同格式的参数
- node.js - mongodb副本集如何与nodejs-mongoose一起工作?