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 > Informix > hhmm ROUND

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 12-26-08, 19:49
robiverson robiverson is offline
Registered User
 
Join Date: Dec 2008
Posts: 5
hhmm ROUND

how can i round hhmm to nearest 30 minutes for ex 1140 round it to 1130 ,1210 to 1200 .

Please let me know .
Reply With Quote
  #2 (permalink)  
Old 12-26-08, 20:10
ibm.ids ibm.ids is offline
Registered User
 
Join Date: Nov 2008
Posts: 64
Stored procedure?
Reply With Quote
  #3 (permalink)  
Old 12-26-08, 21:55
robiverson robiverson is offline
Registered User
 
Join Date: Dec 2008
Posts: 5
i would like to use in the in the query.
Reply With Quote
  #4 (permalink)  
Old 12-27-08, 04:39
ibm.ids ibm.ids is offline
Registered User
 
Join Date: Nov 2008
Posts: 64
stored procedure?
select hhmmround(datetime_value) from ......
Reply With Quote
  #5 (permalink)  
Old 12-27-08, 08:55
robiverson robiverson is offline
Registered User
 
Join Date: Dec 2008
Posts: 5
I have tried it in the query
Routine (hhmmround) can not be resolved.
Reply With Quote
  #6 (permalink)  
Old 12-27-08, 08:58
ibm.ids ibm.ids is offline
Registered User
 
Join Date: Nov 2008
Posts: 64
You have to write your own hhmm_or_whatever_name procedure
Reply With Quote
  #7 (permalink)  
Old 12-29-08, 08:59
fprose fprose is offline
Registered User
 
Join Date: Apr 2003
Location: Phoenix, AZ
Posts: 177
Would need to be a function, not a stored procedure.
__________________
Fred Prose
Reply With Quote
  #8 (permalink)  
Old 12-29-08, 14:37
ibm.ids ibm.ids is offline
Registered User
 
Join Date: Nov 2008
Posts: 64
You're right Fred - function.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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