emuleomo@yes.rutgers.edu (Emuleomo) (07/21/89)
I seem to have run into a very insidious bug when doing date calculations in Ingres. The problem is this. When I do a date calculation that should return a negative number, it sometimes returns zero!! This happens spuriously. e.g. the ESQL/C statement EXEC SQL SELECT date('20-jul-1989')-date('22-jul-1989') INTO :Date_buf1 from a_table; will return "0 days" or "-2 days" intermitently. However, EXEC SQL SELECT date('22-jul-1989')-date('20-jul-1989') INTO :Date_buf1 from a_table; will ALWAYS return "2 days". Ingres GURUS, what is going on here?? E-mail will be greatly appreciated. --Emuleomo O.O. (emuleomo@yes.rutgers.edu) -- ** Research is what I'm doing when I dont know what I'm doing! **