Reputation: 101
based on other forum entries, I believe that I need to utilise the below code to convert a date in Informix to a month:
select
MONTH(DATE_FIELD) as "Month Conversion"
from TABLE
Unfortunately when I run it, I get this error
Error: ERROR Mixed numeric and alpha operands in expression - job_cost_master.jcm_start_date SQLState: 42000 ErrorCode: -1
Upvotes: 0
Views: 350
Reputation: 381
You cannot use a column ALIAS with spaces and/or in quotes. This should work:
select MONTH(DATE_FIELD) as month_conversion from TABLE
Regards
Upvotes: 2