craigorama
Technical User
I have a field [new_time] that displays full date and time like this:
15/05/2006 12:20:00 PM
I'm trying to parse it up and insert it into new columns.
I searched the forums here and found this thread:
I've tried to incorporate the year function into a statement but it hasnt worked correctly. Here is my statement:
First I've added the field:
ALTER TABLE TELLUS_TEMP_UPLOAD ADD LOC_YEAR Date;
Then i've tried to update the new field with the year value of the [new_time] field:
UPDATE TELLUS_TEMP_UPLOAD SET TELLUS_TEMP_UPLOAD.LOC_YEAR = YEAR(NEW_TIME);
Am I going about this in the wrong way? Can the Year function work on a field or only a value?
Thanks for your help!
15/05/2006 12:20:00 PM
I'm trying to parse it up and insert it into new columns.
I searched the forums here and found this thread:
I've tried to incorporate the year function into a statement but it hasnt worked correctly. Here is my statement:
First I've added the field:
ALTER TABLE TELLUS_TEMP_UPLOAD ADD LOC_YEAR Date;
Then i've tried to update the new field with the year value of the [new_time] field:
UPDATE TELLUS_TEMP_UPLOAD SET TELLUS_TEMP_UPLOAD.LOC_YEAR = YEAR(NEW_TIME);
Am I going about this in the wrong way? Can the Year function work on a field or only a value?
Thanks for your help!