Skip to main content
4 of 8
edited tags
Steven D
  • 47.6k
  • 15
  • 123
  • 117

Tool in UNIX to subtract dates

Is there any tool in Solaris UNIX (so no GNU tool available) to subtract dates? I know that in Linux we have gawk that can subtract one date from another. But in Solaris the maximum we have is nawk (improved awk) which cannot perform date calculations. Also I cannot use perl... :(

Is there anyway to do dates calculations like 20100909-20001010 ?

UPDATE: Is bc able to perform dates calculations?

Thanks guys

jyz
  • 687
  • 2
  • 10
  • 17