OUTSYSTEMS WEEK 2 EXAM QUESTIONS
WITH 100% VERIFIED CORRECT
ANSWERS!!
Entities
They are are elements that allow you to persist information in the DB. Think of them as DB
tables.
Primary Key
In Outsystems a primary key is an Entity Identifier, it's a long Int and by default it's value is
automatically calculated. This way it's always unique. You can use other data types as id's or
switch auto number off.
Indexes
They provide faster access to data in the entity.
If you usually search by one or more attributes of the entity, you can create an index based on
those attributes make that search or sort faster.
Static entities
Consist of a set of named values.
Think of it as literal values stored in the DB.
The structure is determined by the static's attributes
The scope for these is global
Protect (Delete rules)
This value prevents deleting records in Entity A while there are associated records in Entity B,
assuming there is a relationship between A & B.
Delete (Delete Rules)
This is also known as a cascading delete. All the records are deleted if you delete.
Ignore (Delete Rule)
, Deleting records in Entity A means only records in that entity are deleted even if there are
records in Entity B. The remaining records are referred to as orphan records
Aggregate
Used to fetch data from the server Database
Property: Max. Records = max number of records fetched from DB
Sort results in Aggregate
Fixed sorting = sorts from A-Z ascending or Z-A for descending order
Dynamic sorting = Can change during runtime, expected input is an expression of type text.
Calculate Values from Grouped Data
I'm Outsystems you can use aggregate functions to calculate values based on groups of identical
data.
Fetch the data in an aggregate:
1. In the attribute with the identical data, use the arrow menu and select group by <attribute>
2. In the attribute to calculate, use the arrow menu and select an aggregate function such as count
☔️: Once you group of use aggregate functions on attributes, those attributes become the only
output of the aggregate
Aggregate a Column into a single Value
Sum: Sums all the values in the column
Avg: calculates avg of values in the column
Max: finds the max value in the column
Min: finds the min value in the column
Count: counts how many rows there are in the column
☔️: the list of available aggregate functions depends on the data type of the columns
Created a Calculated Attribute in an Aggregate
If you need to add more information to each record, namely based on the values returned,
Outsystems allows you to do that. You can add new attributes to the records returned by the
aggregate based on the value of the other attributes
WITH 100% VERIFIED CORRECT
ANSWERS!!
Entities
They are are elements that allow you to persist information in the DB. Think of them as DB
tables.
Primary Key
In Outsystems a primary key is an Entity Identifier, it's a long Int and by default it's value is
automatically calculated. This way it's always unique. You can use other data types as id's or
switch auto number off.
Indexes
They provide faster access to data in the entity.
If you usually search by one or more attributes of the entity, you can create an index based on
those attributes make that search or sort faster.
Static entities
Consist of a set of named values.
Think of it as literal values stored in the DB.
The structure is determined by the static's attributes
The scope for these is global
Protect (Delete rules)
This value prevents deleting records in Entity A while there are associated records in Entity B,
assuming there is a relationship between A & B.
Delete (Delete Rules)
This is also known as a cascading delete. All the records are deleted if you delete.
Ignore (Delete Rule)
, Deleting records in Entity A means only records in that entity are deleted even if there are
records in Entity B. The remaining records are referred to as orphan records
Aggregate
Used to fetch data from the server Database
Property: Max. Records = max number of records fetched from DB
Sort results in Aggregate
Fixed sorting = sorts from A-Z ascending or Z-A for descending order
Dynamic sorting = Can change during runtime, expected input is an expression of type text.
Calculate Values from Grouped Data
I'm Outsystems you can use aggregate functions to calculate values based on groups of identical
data.
Fetch the data in an aggregate:
1. In the attribute with the identical data, use the arrow menu and select group by <attribute>
2. In the attribute to calculate, use the arrow menu and select an aggregate function such as count
☔️: Once you group of use aggregate functions on attributes, those attributes become the only
output of the aggregate
Aggregate a Column into a single Value
Sum: Sums all the values in the column
Avg: calculates avg of values in the column
Max: finds the max value in the column
Min: finds the min value in the column
Count: counts how many rows there are in the column
☔️: the list of available aggregate functions depends on the data type of the columns
Created a Calculated Attribute in an Aggregate
If you need to add more information to each record, namely based on the values returned,
Outsystems allows you to do that. You can add new attributes to the records returned by the
aggregate based on the value of the other attributes