I currently have a Date field in the format of MM/DD/YYYY.
My goal here is to convert the Dates into 1 of 4 quarters, along with the Year. The field to be created will be called QTR_YR.
My first question is what data type do I need to make the QTR_YR field? Should it be Integer (Short or Long), or Date, or Double?
I am old school so I'd prefer VBA but I can use Python.
Best Answer
The query below in VBA should return a string that looks like "Q2 1990" for each record. All credits go to @EvilGenius for this one.
Just make sure your quarter field "QTR_YR" is a Text/String type. If the format "Q2 1990" is not to your taste, you can tweak the format. Concatenation in VBA is done by the ampersand "&" not "+" like most other languages.
Let us know if this works.
Update: As requested, the solution in ArcPy with the UpdateCursor would be: