[英]Mule MEL Date Time Format
I am trying to output data in DD-MON-YY(22-OCT-15)
format to insert into an Oracle DB. 我正在尝试以DD-MON-YY(22-OCT-15)
格式输出数据以插入到Oracle DB中。 I used the MEL expression server.dateTime.format("dd-MMM-yy")
. 我使用了MEL表达式server.dateTime.format("dd-MMM-yy")
。 This outputs data as 22-Oct-15
. 这将输出数据为22-Oct-15
。 See fragment below. 请参阅下面的片段。
<expression-component doc:name="Expression"><![CDATA[if ( flowVars.collection_opening_date == null){
flowVars.collection_opening_date = server.dateTime.format("dd-MMM-yy");
}]]></expression-component>
There is no error from this snippet. 此代码段没有错误。 server.dateTime.format("dd-MMM-yy")
outputs as 22-Oct-15
and my desired format is 22-OCT-15
. server.dateTime.format("dd-MMM-yy")
输出为22-Oct-15
而我所需的格式为22-OCT-15
。 How can I get my desired format? 如何获得所需的格式?
像这样大写: server.dateTime.format("dd-MMM-yy").toUpperCase().
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.