iscurrency

iscurrency, function

def pure isCurrency(code: text): boolean

Returns true if code is a recognized currency code.

Examples

table T = with
  [| as Code |]
  [| "EUR" |]
  [| "USD" |]
  [| "AAA" |]

T.IsCurrency = isCurrency(T.Code)

show table "Currency codes" with
  T.Code
  T.IsCurrency

This produces the following table:

Code IsCurrency
EUR true
USD true
AAA false

See also

User Contributed Notes
0 notes + add a note