如何将logicapps中的文件名从base64转换为字符串,然后过滤它们
如何在逻辑应用中从HTTP中过滤文件?
我的方法是构成这样的函数
toLower(base64ToString(triggerOutputs()['headers']['x-ms-file-name-encoded']))
,但它无法正常工作……我在Logicapp中是全新的,但需要它才能完成一个项目。
How can I filter files from HTTP get request in Logic Apps?
My approach is to compose a function something like this
toLower(base64ToString(triggerOutputs()['headers']['x-ms-file-name-encoded']))
but it's not working... I'm completely new one in LogicApps but need it for one project requirement.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
base64ToString(triggerOutputs()['headers'] ['x-ms-file-name-name-Name-name编码'])
帮助您提取文件的名称。在过滤您选择的文件时,您可以使用条件
连接器,然后将过滤后的文件保存到存储中。例如,这是我的逻辑应用程序。成功运行后,我能够将文件保存到我的一个blob容器中。
如果您试图用其文件名过滤文件,则在两侧使用小写以进行比较以对其进行过滤。
我将以下表达式放在右
中的左侧
:
我正在使用包含来过滤
条件
连接器中的表达式,以便每个包含名称或名称的一部分的文件都添加到我的存储帐户中。另外,我只是使用示例内容存储在我的斑点中(即斑点内容),但是您可以使用所需的内容。更新答案
这有助于从SharePoint文件夹过滤CSV文件,并将被过滤到目标文件夹的文件移动。
注意:确保您是否试图将文件名作为过滤器使用,就像我已经提到的那样,您可以将文件名的案例更改为下部或上部,因为这是有时很少的部分所需的文件夹不会触发。
The
base64ToString(triggerOutputs()['headers']['x-ms-file-name-encoded'])
helps you to extract the names of the files. While filtering the file of your choice then you can useCondition
connector and save the filtered file to your storage. For example here is my logic app.After successful run I could able to save the file into one of my blob containers.
If you are trying to filter the files with its file name then use lowercase on both sides for comparison to get it filtered.
I have placed the below expression in the left
In the right
Note:
I'm using contains to filter the expression in
condition
connector so that every file which contains the name or part of the name gets added to my storage account. Also, I'm just using sample content to store in my blob (i.e., blob content) but you can use the one which you require.Updated Answer
This helps to filter CSV files from the sharepoint folder and moves the files which got filtered to the destination folder.
Note: Make sure if you are trying to use file name as filter, like I have already mentioned you can change case of file name into either Lower or upper as this is the main part where sometimes few of the desired folders won't trigger.