Hi,
I'm working on a Informix4gl module. I'm just trying to find out any built-in function to fetch only the year/month from an INTERVAL YEAR TO MONTH data value.
Please let me know, if there are any functions to do this. If not, let me know for any alternative solutions to attain this.
I work with Informix too, but i really don�t understand your question. Do you want to get only "year" of a year-month value?
---------- Post updated at 11:56 AM ---------- Previous update was at 10:38 AM ----------
Do you find anything as this?
define
var interval year to month,
my_year smallint,
my_month smallint
main
let var = "2010-06"
let my_year = year(var)
let my_month = month(var)
display "Var: ", var
display "Year: ", my_year
display "Month: ", my_month
end main