I need to get average of the hours after (start_date - end_date). *start_date and end_date is in format 'mm/dd/yyyy hh:mi:ss am' . Is there any function in oracle that i can use so that i can directly get the average of the hours in SQL statement?
i'm importing a date ( 13/2/2005 1:20:22 PM) from SQL server to informix. The problem now is informix doesnt accept alphabet in datetime format, so i plan to convert it before the date insert into informix db. But the problem is i dont know any function that can convert the date time from 12 hours format to 24 hours format.
I've looked and can't find a built-in function for ASP that performs averages. If I have a SQL statement that returns thousands of numerical results back to my ASP script, what is the best way to average all of these results?
There will be an unknown number a values between the | and an uknown total number of values. I need to get the average of the number between each of the |'s. Any ideas how to handle that?
I have little golfclub with a leaderboard where each member gets point after each match (1 - 20 points). Is it possible to get the average point of the last 10 records, and what if they only played 7 matches can i get the average of that.
I can subtract a day, but that's by only having ONE integer...what do I do for hours? (i need this because our server uses EST and clients need their TimeZone)
how you convert an integer such as 5 into an hour string so the system identifies it as an hour instead of just the number 5 and then once you do that ("if you need to do that at all") add 5 hours to the current time...
Also is there a way way to add lets say 50 hours to our current time and date so when it is calculated it shows 2 days and 2 hours away from now... If you cant do that it would be nice to know how to change 7.85 into just 7... or 8.94 into just 8... no rounding up or down just the first number before the decimal.
I am using a select sum(tot_daily) as total hours ...it calculates the time incorretly... Example: ID | Tot_hrs | Person ---------------------- 1 5.45 A 2 5.45 A 3 5.45 A
The total hours should be 17 hours 15 mins...but the result comes as 16.35.... Is there a way to calculate it as 17.15 in db level in a select statement
Count number of Database Records between NOW and 24 HOURS EARLIER? I know how to retrieve recordsets etc - its just the date thing I cant grasp. I am stuck getting the 24 hours earlier data capture.
I have a request from the boss to make a report that will require me to display how many hours something has been in a particular state. (As in status). Hard to explain. Anyway, I need to go to the table in the db, find all rows for a particular trouble ticket, find when they were put into one of our 7 statuses, when they were put into another status (this info is already in those rows), then determine how many hours they spent there in each status.
So a ticket report will say that ticket 1000 spent 4 hours in customer research, 5 hrs in our company coding. 3 in our company testing, 4 in customer testing, etc.
The thing is, It has to assume an 8-5 workday, and leave out any hours which don't fall in between 8 am to 5 pm, and also rule out any weekends.
I'm trying to write a script to countdown the number of hours and minutes until tomorrow. So far, this is what I have:
Code: <% response.write(dateDiff("h",now(),date+1)) & " hours and " & dateDiff("m",Time(),date+1) & " Minutes " %> The code above correctly displays the hours until tomorrow. but it's not displaying the minutes correctly. It's displaying the total minutes until tomorrow. If there at 4 hours left until tomorrow it's saying "4 Hours and 240 minutes."
Been playing with the function DateDiff, and with it it's easy to calculate the difference in years/months/days between two dates. However, if i wanted to calculate the difference in Years, Months, Days, Hours, Seconds (a la Ebay bids) how can I do this? Is it easy or complicated?
Ive got some code on my site that shows how current the database is. Basically it looks at fixed text file that I am basing the database on, checks to see iwhen it was created, then displays the time.
My webserver must be on the East Coast and I am on the West Coast, so the time the stamped file time is 3 hours ahead. Code:
building variable width/DB tables etc using getrows instead of movenext. Performance is a major concern as this app requires SSL.
My question is, when does it become more about the challenge of building faster apps vs. getting the job done??? If my calculations are correct, I just added an extra 10,000+ possible hits within a 12 hour day or so.. an extra 10,000 hits???!!! What percentage of applications do you think will ever see this kind of traffic?
Is this insane? If this app ever gets maxed out, will my end users ever realistically notice a difference?