Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have a field with data like Jan 2011.
But, some values are in JAN 2011, some are Jan 2011.
How can i standardize all to says Jan 2011?
i tried the following, but i didn't work.
DATE#(capitalize(MONTH_YEAR), 'MMM YYYY') as MONTH_YEAR,
Going back to the syntax of your first post, maybe you just need to include the month names in a capitalized form in the beggining of the script:
SET MonthNames='JAN;FEB;MAR ...
Hope this helps,
Erich
Try the following expression:
Date(Date#(YourDate,'MMM YYYY'),'MMM YYYY')
Thanks, but still the same.
use:
upper(Yourdate)
Jay
What I suggested works for me, unless I did not understand your requirement.
See the attached file.
ok, but it still didn't work for my case.
upper() will change all to upper but wont keep the date format..
any other way?
My logic is as simple as this. If it is not working for you, either your data is not what you think it is or the processing is erroneous. From my example, I am able to establish the processing seems to be correct. Let us then examine your data and what you are doing. If you can attach a sample data and your script, the forum may be able to help.
ok, if i put that in expression, it works, but in fact, i'm doin it in the script. that's why it wont work.
whats the different formatting it in expression and in the script?
It works in load script also. See the attached file to believe it.
Try
LOAD
capitalize(FULL_NAME) AS FULL_NAME;
select
P.EMPLOYEE AS FULL_NAME
FROM SDDTA.PhoneReport P