CAST DATE computation to Decimal

  • In my Sybase world, I'm trying to generate a decimal value for the following SELECT statement:

    sum(datediff (hh,DateCol_1, DateCol_2))/ 31

    This works in SQL Server:

    select cast(sum(datediff (hh,DateCol_1, DateCol_2))/ 31 as decimal (18,9))

    It is not working in Sybase.. Is there a CONVERT fucntion I cantry?

    BT
  • convert(decimal (5,2),(sum( datediff (hh,DateCompletedByResearch, ReadyOrShippedByFulfillment))/ 31))

    BT

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply