t-sql question

  • I am trying to do the following:

    On running the query

    select 59/60 - I am getting value as 0.

    But actual 59/60 is 0.983333

    I want the select 59/60 to return the actual value which is 0.983333, tried to convert that to int, decimal, float etc

    but nothing worked, please let me know what I should do. Thanks!!

  • select 59/60 -- is doing integer division, that is why it returns 0

    try: select 59/60.0

    😎

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

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