首页 > 其他分享 >[引]Power Automate Use variables and the % notation

[引]Power Automate Use variables and the % notation

时间:2023-12-25 22:45:13浏览次数:29  
标签:Use False notation arg1 variables search value Text True

Variable manipulation and the % notation - Power Automate | Microsoft Learn

变量操作和 % 表示法 - Power Automate | Microsoft Learn

 

In this article
Hardcoded values
Variable names
Basic arithmetic
Comparisons
Show 2 more
Variables are used within flows to store data for further processing. Every variable name must be enclosed by percentage signs (%). The percentage sign is used as a special character to denote variables. Any expression between percentage signs should be evaluated.

 

Occasionally, the percentage sign should be used as a simple character, instead of denoting a calculation. In those cases, it should be escaped using another percentage character (%%).

Power Automate enables you to create complex expressions containing hardcoded values, variable names, arithmetic and logical operations, comparisons and parentheses.

 

Hardcoded values
To include a hardcoded text value inside a variable, use quotes. Every value between the quote characters will be treated as a text value and not as a variable name.

 

Variable names
Variables can be used by adding their name to the expression without any further notation.

 

Basic arithmetic
To make mathematical operations, use all the essential, arithmetic operators, such as addition (+), subtraction (-), multiplication (*), and division (/).

Arithmetic operations are predominantly used with numerical values and variables. However, you can also use the addition operator to concatenate strings. Adding numbers and text strings in the same expression will convert the numbers into text, and concatenate them with the other text strings.


Expand table
Expression Result Result variable type
%5 * 3% 15 Number
%4 / Var% 4 divided by the value of the Variable named “Var” Number
%'this is ' + 'text'% this is text Text
%'This is the number ' + 5% This is the number 5 Text
Comparisons
Besides arithmetic operators, make comparisons using the following operators


Expand table
Operator Description
=, <> Equal/not equal
<, <= Less than/less than or equal
>, >= Greater than/greater than or equal
Keep in mind that comparisons, when evaluated, produce either True or False as a value. Naturally, comparisons can only be done between values of the same type.

Logical operators
Logical operators can also be used to check multiple conditions simultaneously, allowing you to implement more complex logic in a single expression. The supported operators are: AND, OR, and NOT.


Expand table
Expression Result
%Index = 1 OR Index = 2% True if the value of the Index variable is 1 OR 2, otherwise False.
%Index = 4 AND Text = "Four"% True if the value of the Index variable is 4 AND the value of the Text variable is Four, otherwise False.
%NOT(4 <> 4)% Reverses the logical value in the parentheses. In this examples, it returns True.
Additionally, you can use the following logical expressions to check the value of a string or variable.


Expand table
Expression Arguments Description
%StartsWith(arg1,arg2,arg3)% arg1: Text to search into
arg2: Text to search for
arg3: Ignore case (True / False) True if the provided string starts with the specified value, otherwise False.
%NotStartsWith(arg1,arg2,arg3)% arg1: Text to search into
arg2: Text to search for
arg3: Ignore case (True / False) True if the provided string doesn't start with the specified value, otherwise False.
%EndsWith(arg1,arg2,arg3)% arg1: Text to search into
arg2: Text to search for
arg3: Ignore case (True / False) True if the provided string ends with the specified value, otherwise False.
%NotEndsWith(arg1,arg2,arg3)% arg1: Text to search into
arg2: Text to search for
arg3: Ignore case (True / False) True if the provided string doesn't end with the specified value, otherwise False.
%Contains(arg1,arg2,arg3)% arg1: Text to search into
arg2: Text to search for
arg3: Ignore case (True / False) True if the provided string contains the specified value, otherwise False.
%NotContains(arg1,arg2,arg3)% arg1: Text to search into
arg2: Text to search for
arg3: Ignore case (True / False) True if the provided string doesn't contain the specified value, otherwise False.
%IsEmpty(arg1)% arg1: Text to check True if the provided string doesn't contain any characters, otherwise False.
%IsNotEmpty(arg1)% arg1: Text to check True if the provided string contain one or more characters, otherwise False.
Parentheses
To change the operators' priority, use parentheses. Parentheses are handled the same way as in algebra and programming languages.

 

标签:Use,False,notation,arg1,variables,search,value,Text,True
From: https://www.cnblogs.com/freeliver54/p/17927137.html

相关文章

  • Caused by: java.sql.SQLSyntaxErrorException: You have an error in your SQL synta
    问题描述Causedby:java.sql.SQLSyntaxErrorException:YouhaveanerrorinyourSQLsyntax;checkthemanualthatcorrespondstoyourMySQLserverversionfortherightsyntaxtousenear'orderwherestatus!='已完成''atline1问题解决最后发现时因为......
  • react_hooks系列 useMemo
    一、概念和作用​写在函数式组件里的“函数调用代码”。如果函数式组件重新渲染时,每次都会执行“调用函数的代码”。如果不是必须的,那么就是性能的浪费。useMemo就是解决这个问题的。即:useMemo是防止不必要的的函数调用。​文字描述总是让你很难理解。很抽象。还是要看代码的......
  • 控制台打印时显示的文件来源没有显示.vue文件,而是出现了一堆index.js??clonedRuleSet-
    控制台打印时显示的文件来源没有显示.vue文件,而是出现了一堆index.js??clonedRuleSet-40.use[0]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-optio…,看不出来打印的语句来自哪个vue组件检查发现edge打印显示正常,谷歌打印是以上这样的,谷歌设置一下配置 ......
  • Q:以非root用户编辑定时任务报错You are not allowed to use this program(crontab)
    编辑定时删除文件任务时报错crontab-e编辑定时任务时报错,如下图所示问题原因:/etc/cron.allow中没有添加对应的用户名解决办法:切换到root用户,在/etc/cron.allow中添加对应的用户名编辑定时任务:crontab-e #每天中午13点,定时删除/var路径内30天以上的文件或者文件夹013*......
  • 【flink番外篇】4、flink的sink(内置、mysql、kafka、redis、clickhouse、分布式缓存、
    文章目录Flink系列文章一、maven依赖二、Jdbc/mysql示例1、maven依赖2、实现1)、userbean2)、内部匿名类实现3)、lambda实现4)、普通继承RichSinkFunction实现5)、完整代码3、验证本文介绍了Flink将数据sink到mysql中,其实是通过jdbc来将数据sink到rmdb中,mysql是一个常见的数据库,故......
  • 强化学习算法真的适合于你的应用吗 —— 强化学习研究方向(研究领域)现有的不足(短板、
    外文原文:WhyYou(Probably)Shouldn’tUseReinforcementLearning地址:https://towardsdatascience.com/why-you-shouldnt-use-reinforcement-learning-163bae193da8中文翻译版本(ChatGPT3.5翻译:)有关这项技术存在很大的炒作,而且理由充分,因为这可能是实现通用人工智能的......
  • Jackson Annotations(注解)详解
    转载自:https://blog.csdn.net/wjw465150/article/details/1273268491.概述在本教程中,我们将深入研究JacksonAnnotations。我们将了解如何使用现有的注解,如何创建自定义注解,最后,如何禁用它们。2.Jackson序列化注解首先,我们将看一下序列化注解。2.1.@JsonAnyGetter@J......
  • ClickHouse(19)ClickHouse集成Hive表引擎详细解析
    目录Hive集成表引擎创建表使用示例如何使用HDFS文件系统的本地缓存查询ORC输入格式的Hive表在Hive中建表在ClickHouse中建表查询Parquest输入格式的Hive表在Hive中建表在ClickHouse中建表查询文本输入格式的Hive表在Hive中建表在ClickHouse中建表资料分享参考文......
  • Spring的Bean后置处理器之AnnotationAwareAspectJAutoProxyCreator
    本文能帮你回答以下几个问题;AnnotationAwareAspectJAutoProxyCreator后置器的作用是什么?SpringAOP自动增强bean是如何实现的。如何在spring上下文添加AnnotationAwareAspectJAutoProxyCreator?如何利用ProxyFactory硬编码实现一个bean的增强?AnnotationAwareAspectJAutoProx......
  • 阿里云安装opensuse,并开启xrdp,让windows远程连接
    一、安装gnome桌面和xrdpzypperupdatezypperinstallpatterns-gnome-gnome_basicxrdp 二、通过yast开启vnc保存退出三、windows下使用远程桌面连接输入账号密码,即可登录。 ......