You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/en/docs/refguide/modeling/domain-model/oql/oql-expression-syntax.md
+126Lines changed: 126 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -692,10 +692,13 @@ These are the currently supported functions:
692
692
* LENGTH
693
693
* LOCATE
694
694
* LOWER
695
+
* LTRIM
695
696
* RANGEBEGIN
696
697
* RANGEEND
697
698
* REPLACE
698
699
* ROUND
700
+
* RTRIM
701
+
* TRIM
699
702
* UPPER
700
703
701
704
### CAST{#cast}
@@ -1329,6 +1332,47 @@ SELECT * FROM Sales.Customer WHERE LOWER(LastName) = 'doe'
1329
1332
This query can no longer take advantage of an index for `LastName` for comparison, resulting in a performance decrease.
1330
1333
{{% /alert %}}
1331
1334
1335
+
### LTRIM{#ltrim}
1336
+
1337
+
Removes one or more leading characters from a `string`. If no character is specified for trimming, space is used.
1338
+
1339
+
{{% alert color="info" %}}
1340
+
This function was introduced in Mendix version 11.11.0.
1341
+
{{% /alert %}}
1342
+
1343
+
#### Syntax
1344
+
1345
+
The syntax is as follows:
1346
+
1347
+
```sql
1348
+
LTRIM ( expression [, character ] )
1349
+
```
1350
+
1351
+
##### expression
1352
+
1353
+
`expression` is any string expression to be trimmed. If `expression` is `NULL`, the function will return `NULL`.
1354
+
1355
+
##### character
1356
+
1357
+
`character` is an optional single character string expression containing the character to remove from the start of the string. If omitted, the space character is used instead.
1358
+
1359
+
{{% alert color="info" %}}
1360
+
Only a single character is supported. `character` parameters with more than one character may not work in all supported databases.
1361
+
{{% /alert %}}
1362
+
1363
+
If the expression string consists entirely of `character`, everything will be trimmed and the function will return a zero-length string.
@@ -1507,6 +1551,47 @@ SELECT ROUND((Price : 7), 2) as RoundedPrice, Price : 7 FROM Sales.Order
1507
1551
| 0.33 | 3.33333333 |
1508
1552
| 1.17 | 1.17142857 |
1509
1553
1554
+
### RTRIM{#rtrim}
1555
+
1556
+
Removes one or more trailing characters from a `string`. If no `character` is specified for trimming, space is used.
1557
+
1558
+
{{% alert color="info" %}}
1559
+
This function was introduced in Mendix version 11.11.0.
1560
+
{{% /alert %}}
1561
+
1562
+
#### Syntax
1563
+
1564
+
The syntax is as follows:
1565
+
1566
+
```sql
1567
+
RTRIM ( expression [, character ] )
1568
+
```
1569
+
1570
+
##### expression
1571
+
1572
+
`expression` is any string expression to be trimmed. If `expression` is `NULL`, the function will return `NULL`.
1573
+
1574
+
##### character
1575
+
1576
+
`character` is an optional single character string expression containing the character to remove from the end of the string. If omitted, the space character is used instead.
1577
+
1578
+
{{% alert color="info" %}}
1579
+
Only a single character is supported. `character` parameters with more than one character may not work in all supported databases.
1580
+
{{% /alert %}}
1581
+
1582
+
If the expression string consists entirely of `character`, everything will be trimmed and the function will return a zero-length string.
Removes one or more leading and trailing characters from a `string`. If no `character` is specified for trimming, space is used.
1650
+
1651
+
{{% alert color="info" %}}
1652
+
This function was introduced in Mendix version 11.11.0.
1653
+
{{% /alert %}}
1654
+
1655
+
#### Syntax
1656
+
1657
+
The syntax is as follows:
1658
+
1659
+
```sql
1660
+
TRIM ( expression [, character ] )
1661
+
```
1662
+
1663
+
##### expression
1664
+
1665
+
`expression` is any string expression to be trimmed. If `expression` is `NULL`, the function will return `NULL`.
1666
+
1667
+
##### character
1668
+
1669
+
`character` is an optional single character string expression containing the character which will be removed from the beginning and end of the string. If omitted, the space character is used.
1670
+
1671
+
{{% alert color="info" %}}
1672
+
Only a single character is supported. `character` parameters with more than one character may not work in all supported databases.
1673
+
{{% /alert %}}
1674
+
1675
+
If the expression string consists entirely of `character`, everything will be trimmed and the function will return a zero-length string.
0 commit comments