syntax:start
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | |||
syntax:start [2021/07/21 15:22] – dmitry | syntax:start [2025/06/24 00:18] (current) – dmitry | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Expressions ====== | ====== Expressions ====== | ||
- | In EasyMorph you can use expressions to [[transformations: | + | In EasyMorph, you can use expressions to [[transformations: |
* Numbers and text strings (see [[syntax: | * Numbers and text strings (see [[syntax: | ||
Line 9: | Line 9: | ||
=== Field names === | === Field names === | ||
- | You can refer to values in columns of the table where the expression is calculated by putting column names in square brackets, e.g. [Amount]. Field names can include spaces, digits and non-alphabetical characters in any order. | + | You can refer to values in columns of the table where the expression is calculated by putting column names in square brackets, e.g. [Amount]. Field names can include spaces, digits, and non-alphabetical characters in any order. |
When expression is calculated for a row, field names are replaced with values in these fields stored in the row. It's not possible to refer to values from another row or another table. | When expression is calculated for a row, field names are replaced with values in these fields stored in the row. It's not possible to refer to values from another row or another table. | ||
- | Field names are case sensitive -- i.e. [Total], [TOTAL] and [total] are 3 different field names. | + | Field names are case sensitive -- i.e. [Total], [TOTAL], and [total] are 3 different field names. |
=== Parameters === | === Parameters === | ||
Line 29: | Line 29: | ||
=== Example 1 === | === Example 1 === | ||
- | Let's assume we want to calculate new field 'Net Amount' | + | Let's assume we want to calculate |
[Price] * [Quantity] * ( 100 - [Discount %] ) / 100 | [Price] * [Quantity] * ( 100 - [Discount %] ) / 100 | ||
Line 42: | Line 42: | ||
=== Example 2 === | === Example 2 === | ||
- | Let's assume we want to calculate new field 'Total Tax' using the following expression: | + | Let's assume we want to calculate |
[Amount] * if( [Province]=' | [Amount] * if( [Province]=' | ||
Line 55: | Line 55: | ||
- | === A few transformations | + | === A few actions |
* [[transformations: | * [[transformations: | ||
* [[transformations: | * [[transformations: | ||
Line 62: | Line 62: | ||
* [[transformations: | * [[transformations: | ||
* [[transformations: | * [[transformations: | ||
+ | |||
+ | === Generating expressions from description === | ||
+ | Starting from v5.9.6, it's possible to generate an expression from a description in plain English. To learn more, read [[syntax: |
syntax/start.txt · Last modified: 2025/06/24 00:18 by dmitry