找的值一定在“车”和“号”后面么,会不会出现其他字符?
提供个思路,将原来表格的所有列合并在一起,然 ...
也不知道是提取首字符还是所有字符,自己修改下吧。
代码:
- let
源 = Excel.CurrentWorkbook(){[Name="表1_3"]}[Content],
更改的类型 = Table.TransformColumnTypes(源,{{"列1", type text}, {"列2", type text}, {"列3", type text}, {"列4", type text}, {"列5", type any}, {"列6", type text}, {"列7", type any}, {"列8", type any}, {"列9", type text}, {"列10", type text}, {"列11", type text}, {"列12", type text}}),
提升的标题 = Table.PromoteHeaders(更改的类型, [PromoteAllScalars=true]),
更改的类型1 = Table.TransformColumnTypes(提升的标题,{{"Column1", type text}, {"Column2", type text}, {"Column3", type text}, {"Column4", type text}, {"Column5", type any}, {"Column6", type text}, {"Column7", type any}, {"Column8", Int64.Type}, {"Column9", type text}, {"Column10", type text}, {"Column11", type text}, {"Column12", type text}}),
插入的合并列 = Table.AddColumn(更改的类型1, "合并列", each Text.Combine({[Column1], [Column2], [Column3], [Column4], Text.From([Column5], "zh-CN"), [Column6], Text.From([Column7], "zh-CN"), Text.From([Column8], "zh-CN"), [Column9], [Column10], [Column11], [Column12]}, ""), type text),
已插入分隔符之后的文本 = Table.AddColumn(插入的合并列, "提取字符", each Text.AfterDelimiter([合并列], "车号"), type text)
in
已插入分隔符之后的文本
复制代码
9813012005492.zip
(17.77 KB, 下载次数: 0)
|