I am trying to do something that seems simple.
I want to parse a int field. It always contains 8 characters. The field is used to hold a date yyyymmdd
I need to pull the characters 5 and 6. I can pull the first 4 (Left()) and last 2 (Right()) but the middle 2? Mid() would be the perfect match except I am running this against a SQL2K box.
<cfquery datasource="invoice" name="getInvDate">
select ord_dt, left(ord_dt, 4) as y, mid(ord_dt,5,6) as m
from db
EORDHDR
where slspsn_no = 'I01'
order by y, m
</cfquery>
Any ideas??
I want to parse a int field. It always contains 8 characters. The field is used to hold a date yyyymmdd
I need to pull the characters 5 and 6. I can pull the first 4 (Left()) and last 2 (Right()) but the middle 2? Mid() would be the perfect match except I am running this against a SQL2K box.
<cfquery datasource="invoice" name="getInvDate">
select ord_dt, left(ord_dt, 4) as y, mid(ord_dt,5,6) as m
from db
where slspsn_no = 'I01'
order by y, m
</cfquery>
Any ideas??