ksh math

From: Cohen, Andy (Andy.Cohen_at_cognex.com)
Date: 06/30/04

  • Next message: Cohen, Andy: "SUMMARY: ksh math"
    Date: Wed, 30 Jun 2004 16:09:32 -0400
    To: "Tru64-Unix-Managers (E-mail)" <tru64-unix-managers@ornl.gov>
    
    

    I don't know what I'm missing -- all I want to do is do some very basic math on a variable but I can't figure it out. I've searched the archives, google, manuals, etc. and can't find anything that clarifies it.

    I have a variable $RUN_DAY and I want to subtract one (1) from it. How do I do that?

    I thought it would be:

        export PREV_DAY=${RUN_DAY}-1

    but it doesn't work. I've tried quite a number of variations on this all to no avail.

    I'm using:
        Tru64 5.1A
        korn shell (ksh)

    Thank you!
    Andy Cohen
    Database Systems Administrator
    Cognex Corporation
    1 Vision Drive
    Natick, MA 01760
    508-650-3079


  • Next message: Cohen, Andy: "SUMMARY: ksh math"