Ceiling DataWindow expression function
Description
Retrieves the smallest whole number that is greater than or
equal to a specified limit.
Syntax
|
1 |
<span>Ceiling</span> ( <span>n</span> ) |
|
Argument |
Description |
|---|---|
|
n |
The number for which you want the smallest |
Return Values
The datatype of n. Returns the smallest
whole number that is greater than or equal to n.
Examples
These expressions both return -4:
|
1 |
<span>Ceiling</span>(-4.2)<br> <br><span>Ceiling</span>(-4.8) |
This expression for a computed field returns ERROR
if the value in discount_amt is greater than the smallest
whole number that is greater than or equal to discount_factor
times price. Otherwise, it returns discount_amt:
|
1 |
If(discount_amt <= <span>Ceiling</span>(discount_factor * price),<br>String(discount_amt), "ERROR") |
To pass this validation rule, the value in discount_amt
must be less than or equal to the smallest whole number that is
greater than or equal to discount_factor times price:
|
1 |
discount_amt <= <span>Ceiling</span>(discount_factor * price) |
See Also
Document get from Powerbuilder help
Thank you for watching.
Subscribe
Login
0 Comments
Oldest