Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a field called [Event Date Time] which is formatted as MM/DD/YYYY and is numeric so, 11/12/2016
I want to display just the MM (months) in a list box. In the script, how can I pull out just the month and convert it to just display NOV for the above date.
HI just say,
month( [Event Date Time]) as Event Date Time]
It ll give u month name as NOV
Sachin
Date([Event Date Time],'MMM')
When I enter this in my script I get errors and I cannot reload. Am I missing something other than
MONTH([Event Date Time], 'MMM') ??
Try this?
Month([Event Date Time]) AS Month
Month takes only one parameter...
Hi Evan,,
Use the below script and use the Month field in the list box
Test:
LOAD
"[Event Date Time]",
month("[Event Date Time]") as Month
FROM
********** source.
If your [Event Date Time] field is not a dual value already, then you can try with
Month(Date#([Event Date Time],'MM/DD/YYYY'))
else this expression should be sufficient:
Month([Event Date Time])
hope this helps
regards
Marco
!Hi,
The first thing you have to do is, to say what is the format of the date in date# function.
And you can use the date function to tell how the data should be shown.
While using Month(date()), the output will be your expected format 'Nov'.
You can use the following function.
load
month(date(Date#([Event Date Time],'MM/DD/YYYY'))) as [Event Date Time]
from source_table_name;
Attached qvw for your reference.
Regards,
Vivek
try below script
a:
LOAD * INLINE [
"Event Date Time"
11/12/2016
12/12/2016
13/11/2016
14/12/2016
];
Result:
LOAD
Month( "Event Date Time") as NewMonth
Resident a;
HI just say,
month( [Event Date Time]) as Event Date Time]
It ll give u month name as NOV
Sachin