Working with the following statement which is a SQL 2000 view.:SELECT LEFT(oehdrhst_sql.inv_dt, 4) AS [Invoice Year], LEFT(RIGHT(oehdrhst_sql.inv_dt, 4), 2) AS [Invoice Month], RIGHT(oehdrhst_sql.inv_dt, 2) AS [Invoice Day], oelinhst_sql.prod_cat AS [Product Category], oelinhst_sql.sls_amt AS [Sales Amount], LEFT(oehdrhst_sql.ord_dt, 4) AS [Order Year], LEFT(RIGHT(oehdrhst_sql.ord_dt, 4), 2) AS [Order Month], RIGHT(oehdrhst_sql.ord_dt, 2) AS [Order Day]FROM dbo.arcusfil_sql arcusfil_sql INNER JOIN dbo.oehdrhst_sql oehdrhst_sql ON arcusfil_sql.cus_no = oehdrhst_sql.cus_no INNER JOIN dbo.arslmfil_sql arslmfil_sql ON oehdrhst_sql.slspsn_no = arslmfil_sql.slspsn_no INNER JOIN dbo.oelinhst_sql oelinhst_sql ON oehdrhst_sql.ord_no = oelinhst_sql.ord_no AND oehdrhst_sql.inv_no = oelinhst_sql.inv_noWHERE (oehdrhst_sql.inv_dt >= 20100401)
I would like to be able to just have this automatically pull in the current fiscal year which starts on 04/01 with out having to come in once a year and change the year. odhdrhst_sql.inv_dt is an int