【问题标题】:How to replace commas within double quotes in a CSV using Power Automate?如何使用 Power Automate 替换 CSV 中双引号内的逗号?
【发布时间】:2020-10-14 22:29:08
【问题描述】:

我正在尝试在 Power Automate 中将 CSV 转换为 JSON。我被卡住了,因为我的一些 CSV 值在双引号中包含逗号。我用

分割每一行

split(outputs('CurrentTableRow'), ',')

这当然会在引号之间拆分值。

我还没有找到替换逗号的方法。我已经浏览论坛好几天了...

我需要替换双引号内的逗号或防止双引号内的值拆分。

【问题讨论】:

    标签: json csv power-automate


    【解决方案1】:

    我绕过这个问题的解决方案是使用 decodeBase64() 函数:

    replace(body('Json_object')?['Description'],decodeBase64('LA=='), '*$*')
    

    'LA==' 匹配到 , 在 Base64 中

    The box before running

    The result after running the flow

    【讨论】:

    • 这如何解决问题?发帖人的问题是他们需要替换“引号”中的逗号,并保留“引号”之外的逗号。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2016-03-18
    • 2014-12-06
    • 1970-01-01
    • 1970-01-01
    • 2017-08-08
    • 2020-05-21
    • 1970-01-01
    相关资源
    最近更新 更多