AWS Security ChangesHomeSearch

AWS appstudio documentation change

Service: appstudio · 2025-03-02 · Documentation low

File: appstudio/latest/userguide/data-entities-edit-data-actions.md

Summary

Added documentation about data action condition operators and examples, including operator support by database type and practical usage examples

Security assessment

The changes focus on adding technical documentation about condition operators and their usage in database queries. There is no mention of security vulnerabilities, access control, or security-related features in the changes.

Diff

diff --git a/appstudio/latest/userguide/data-entities-edit-data-actions.md
index 9ae952514..4b9f41916 100644
--- a/appstudio/latest/userguide/data-entities-edit-data-actions.md
+++ b/appstudio/latest/userguide/data-entities-edit-data-actions.md
@@ -5 +5 @@
-Creating data actionsEditing or configuring data actionsDeleting data actions
+Creating data actionsEditing or configuring data actionsCondition operators and examplesDeleting data actions
@@ -14,0 +15,3 @@ Data actions are used in applications to run actions on an entity's data, such a
+  * [Data action condition operators and examples](./data-entities-edit-data-actions.html#data-entities-data-action-operators)
+    * [Condition operator support by database](./data-entities-edit-data-actions.html#data-entities-data-action-operators-support)
+    * [Data action condition examples](./data-entities-edit-data-actions.html#data-entities-data-action-operators-examples)
@@ -70 +73 @@ To delete a join, choose the trash icon next to it. This will remove any fields
-  4. In **Conditions** , add, edit, or remove rules that filter the output of the query. You can organize rules into groups, and you can chain together multiple rules with `AND` or `OR` statements.
+  4. In **Conditions** , add, edit, or remove rules that filter the output of the query. You can organize rules into groups, and you can chain together multiple rules with `AND` or `OR` statements. For more information about the operators you can use, see Data action condition operators and examples.
@@ -80,0 +84,78 @@ To delete a join, choose the trash icon next to it. This will remove any fields
+## Data action condition operators and examples
+
+You can use condition operators to compare a configured expression value with an entity column to return a subset of database objects. The operators that you can use depend on on the data type of the column, and the type of database that the entity is connected to, such as Amazon Redshift, Amazon Aurora, or Amazon DynamoDB.
+
+The following condition operators can be used with all database services:
+
+  * `=` and `!=`: Available for all data types (excluding primary key columns).
+
+  * `<=`, `>=`, `<`, and `>=`: Available only to numerical columns.
+
+  * `IS NULL` and `IS NOT NULL`: Used to match columns that have null or empty values. Null values are often interpreted differently in each database, however in App Studio, the `NULL` operator matches and returns records that have null values in the connected database table.
+
+
+
+
+The following condition operators can only be used in entities that are connected to database services that support them:
+
+  * `LIKE` and `NOT LIKE`(Redshift, Aurora): Used for performing pattern-based queries in the connected database. The `LIKE` operator provides flexibility in search functionality because it finds and returns records that fit the specified patterns. You define the patterns using wildcard characters that match any character or sequence of characters within the pattern. Each database management system has a unique set of wildcard characters, but the two most popular are `%` to represent any number of characters (including 0), and `_` to represent a single character.
+
+  * `Contains` and `Not Contains` (DynamoDB): Used for performing a case-sensitive search to determine whether the given text is found within the column values. 
+
+  * `Starts With` and `Not Starts With` (DynamoDB): Used for performing a case-sensitive search to determine whether the given text is found at the beginning of the column values. 
+
+
+
+
+### Condition operator support by database
+
+The following table shows which data action condition operators are supported by each database that can connect to App Studio.
+
+| =, !=, <, >, <=, >= | LIKE, NOT LIKE | Contains, Not Contains | Starts With, Not Starts With | IS NULL, IS NOT NULL  
+---|---|---|---|---|---  
+**DynamoDB** |  Yes |  No |  Yes |  Yes |  Yes  
+**Aurora** |  Yes |  Yes |  No |  No |  Yes  
+**Redshift** |  Yes |  Yes |  No |  No |  Yes  
+  
+### Data action condition examples
+
+Consider the following database table, which includes multiple items with `name`, `city`, and `hireDate` fields.
+
+name | city | hireDate  
+---|---|---  
+Adam |  Seattle |  2025-03-01  
+Adrienne |  Boston |  2025-03-05  
+Bob |  Albuquerque |  2025-03-06  
+Carlos |  Chicago |  2025-03-10  
+Caroline |  NULL |  2025-03-12  
+Rita |  Miami |  2025-03-15  
+  
+Now, consider creating data actions in App Studio that return the `name` field for items that match specified conditions. The following list contains condition examples and the values that the table returns for each. 
+
+###### Note
+
+The examples are formatted as SQL examples– they may not appear as they do in App Studio, but are used to illustrate the behavior of the operators.
+
+  * `WHERE name LIKE 'Adam'`: Returns `Adam`.
+
+  * `WHERE name LIKE 'A%'`: Returns `Adam` and `Adrienne`.
+
+  * `WHERE name NOT LIKE 'B_B'`: Returns `Adam`, `Adrienne`, `Carlos`, `Caroline`, and `Rita`.
+
+  * `WHERE contains(name, 'ita')`: Returns `Rita`.
+
+  * `WHERE begins_with(name, 'Car')`: Returns `Carlos` and `Caroline`.
+
+  * `WHERE city IS NULL`: Returns `Caroline`.
+
+  * `WHERE hireDate < "2025-03-06"`: Returns `Adam` and `Adrienne`.
+
+  * `WHERE hireDate >= DateTime.now().toISODate()`: Note that `DateTime.now().toISODate()` returns the current date. In a scenario where the current date is 2025-03-10, the expression returns `Carlos`, `Caroline`, and `Rita`.
+
+
+
+
+###### Tip
+
+For more information about comparing dates and times in expressions, see [Date and time](./expressions.html#expressions-date-time).
+