Re: Difference between two DATETIME fields
Posted in 1998
Ronnie Diaz wrote: > I have two DATETIME fields, and I want to know the number of days > between the two dates. Is there a simple SELECT statement I can use to > get that? Depends on what you mean by "simple". DATETIME subtraction results in a INTERVAL, so: untested, but it would something like: SELECT extend( (dt_last - dt_first ), day to day ) ... -- //////////////// ======================================================= ////////// // Dennis J. Pimple Informix Software, Inc. ////// / /// Principal Consultant 6300 S Syracuse Way Ste 205 ///// // //// dennisp@informix.com Englewood CO 80111 //// // ///// /// // ////// recept: 303-850-0210 // // /////// direct: 303-740-5611 Opinions expressed are mine, / /////////// fax: 303-779-4025 and do not necessarily //////////////// http://www.informix.com reflect those of my employer