swirl Guide to OmniMark 5   OmniMark home
docs home 
IndexConceptsTasksSyntaxLibrariesOMX VariablesErrors
 
  Related Syntax    
operator   >=    

Return type: Boolean
Returns:       

True if the first numeric expression is equal to or greater than the second, and false otherwise.



Syntax
  expression1 >= expression2


Purpose

Determine whether one expression is greater than or equal to another with the >= operator. You can use it with any data type expression.

To compare BCD numbers, you must include the ombcd.xin file in your program. To compare floating point numbers, include the omfloat.xin file. You can compare values of mixed data types (for example, BCD numbers and integers) as long as you follow the rules listed in Operations with mixed data types.

For example:

  ; Comparing strings for >=
  process
     local stream string-1 initial {"Catch-up"}
     local stream string-2 initial {"Catch-22"}
     do when string-1 < string-2
        output string-1
            || " < "
            || string-2
            || "%n"
     else when string-1 >= string-2
        output string-1
            || " >= "
            || string-2
            || "%n"
     done
  ; Output: "Catch-Up >= Catch-22"

Mixed data type example:

  include "ombcd.xin"
  process
     local integer one-integer initial {33}
     local bcd one-bcd initial {33}
     do when (one-bcd >= one-integer)
        output "Correct. bcd of "
            || "d" % one-bcd
            || " shown as greater than or equal to integer of "
            || "d" % one-integer
            || ".%n"
     else
        output "Error. bcd of "
            || "d" % one-bcd
            || " shown as not greater than or equal to integer of "
            || "d" % one-integer
            || ".%n"
     done
  ; Output: "Correct. BCD of 33 shown as greater than or equal to integer of 33."

This operator has two deprecated synonyms: is greater-equal and isnt less-than.

    Related Syntax
   <
 
 
----  

Top [ INDEX ] [ CONCEPTS ] [ TASKS ] [ SYNTAX ] [ LIBRARIES ] [ OMX ] [ OMX ] [ ERRORS ]

Generated: August 11, 2000 at 3:06:57 pm
If you have any comments about this section of the documentation, send email to docerrors@omnimark.com

Copyright © OmniMark Technologies Corporation, 1988-2000.