Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
Database Servers
DB2InformixIngresMS SQLOraclePervasive.SQLPostgreSQLProgressSybase
Desktop Databases
FileMakerFoxProMS AccessParadox
General
General DB TopicsDatabase Theory
Related Topics
Java Development.NET DevelopmentVB DevelopmentMore Topics ...

Database Forum / Informix Topics / June 2008

Tip: Looking for answers? Try searching our database.

how to do diff for 2 date value in informix?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
vchu - 24 Jun 2008 00:28 GMT
Hi All,

I am trying to subtract a datetime field with now(current), and like to see
something like

i.e. 6.56 days

round((interval(0) minute(9) to minute  + (extend(current, year to minute) -
t.last_reported_dt))/60/24,2) as inmins,

can u help pls?
Jonathan Leffler - 24 Jun 2008 06:45 GMT
> I am trying to subtract a datetime field with now(current), and like to see
> something like
[quoted text clipped - 3 lines]
> round((interval(0) minute(9) to minute  + (extend(current, year to minute) -
> t.last_reported_dt))/60/24,2) as inmins,

This was discussed in this news group just last week.

Try looking for iv_seconds with Google.

Signature

Jonathan Leffler                   #include <disclaimer.h>
Email: jleffler@earthlink.net, jleffler@us.ibm.com
Guardian of DBD::Informix v2008.0229 -- http://dbi.perl.org/

publictimestamp.org/ptb/PTB-3565 tiger 2008-06-24 03:00:05
506A57E325A796CE9818DFAC32C0D9710B45F5FA3595D63F

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.