expression AND expressionThis procedure lists all customers with credit limits between two values (supplied by the user and stored in the variables low-credit and hi-credit). The expressions Customer.CreditLimit >= low-credit and Customer.CreditLimit <= hi-credit are logical expressions because each yields a true or false value. Using the AND operator to join these logical expressions results in a logical expression that follows the WHERE keyword.
DEFINE VARIABLE low-credit LIKE credit-limit LABEL "Low Credit Limit".DEFINE VARIABLE hi-credit LIKE credit-limit LABEL "High Credit Limit".REPEAT:SET low-credit hi-credit WITH FRAME cr-range.FOR EACH Customer NO-LOCK WHERE(Customer.CreditLimit >= low-credit) AND(Customer.CreditLimit <= hi-credit):DISPLAY Customer.CustNum Customer.Name Customer.CreditLimit.END.END.
© 2012 Progress Software Corporation and/or its subsidiaries or affiliates. |