If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Adabas > need to find sum of hours min and seconds from datestamp

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 06-01-10, 06:32
kavithakanagavel kavithakanagavel is offline
Registered User
 
Join Date: May 2010
Posts: 4
need to find sum of hours min and seconds from datestamp

Table:



32 Resolve 2010-05-31 13:05:32.000 balaji Resolved NULL
32 Update 2010-05-31 12:00:36.000 service progress balaji
32 Update 2010-05-28 16:07:26.000 Nithya Pending NULL
32 Opeen 2010-05-28 14:37:05.000 service progress gowri

1)32 is incident no
2)next column istype
3)Datestamp
4)Operator
5)problem_status
6)assignee_name


need to calculate the total miutes and hours,days
in the table
id open by operator, and assigned to assignee_name column
first the problem_status is progress at datestamp 2010-05-28 14:37:05.000
and then the assignee_name mark as pending at 2010-05-28 16:07:26.000
then the operator open the id at 2010-05-31 12:00:36.000 assigned to assignee_name assignee resolved at 2010-05-31 13:05:32.000


i need to calculate total min and hours with reference to problem status and datestamp

so

from 2010-05-28 14:37:05.000 to 2010-05-28 16:07:26.000 problem_status is progress

from 2010-05-28 14:37:05.000 to 2010-05-31 12:00:36.000 is pending and from 2010-05-31 12:00:36.000 to 2010-05-31 13:05:32.000 progress

finally i need to get total progress minutes,hours and pending min,hours

noteroblem _status column varies so we cannot give where condition
ie where problem_status='pending'
Reply With Quote
  #2 (permalink)  
Old 06-02-10, 04:11
kavithakanagavel kavithakanagavel is offline
Registered User
 
Join Date: May 2010
Posts: 4
need a sql query

Table:



32 Resolve 2010-05-31 13:05:32.000 balaji Resolved NULL
32 Update 2010-05-31 12:00:36.000 service progress balaji
32 Update 2010-05-28 16:07:26.000 Nithya Pending NULL
32 Opeen 2010-05-28 14:37:05.000 service progress gowri

1)32 is incident no
2)next column istype
3)Datestamp
4)Operator
5)problem_status
6)assignee_name


need to calculate the total miutes and hours,days
in the table
id open by operator, and assigned to assignee_name column
first the problem_status is progress at datestamp 2010-05-28 14:37:05.000
and then the assignee_name mark as pending at 2010-05-28 16:07:26.000
then the operator open the id at 2010-05-31 12:00:36.000 assigned to assignee_name assignee resolved at 2010-05-31 13:05:32.000


i need to calculate total min and hours with reference to problem status and datestamp

so

from 2010-05-28 14:37:05.000 to 2010-05-28 16:07:26.000 problem_status is progress

from 2010-05-28 14:37:05.000 to 2010-05-31 12:00:36.000 is pending and from 2010-05-31 12:00:36.000 to 2010-05-31 13:05:32.000 progress

finally i need to get total progress minutes,hours and pending min,hours

noteroblem _status column varies so we cannot give where condition
ie where problem_status='pending'
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On