Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Wrong Calculation
Message
From
02/04/2019 07:56:33
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Wrong Calculation
Miscellaneous
Thread ID:
01667823
Message ID:
01667823
Views:
55
Sir while using SQLSERVER 2012 I have these codes
select top 1 reading,emp_start,emp_end  from bin1_final order by date

SELECT top 1 reading,(datediff(second,emp_start,emp_end)) as x, 3600 as y from bin1_final

SELECT top 1 (reading/(datediff(second,emp_start,emp_end))*3600) as y from bin1_final
The result looks like shown in attachment.

The correct answer is
50135/17808*3600= 10135
but is showing only 7200





Please help
Next
Reply
Map
View

Click here to load this message in the networking platform