contradicting date identifier definitions in datestr and datetime

1 回表示 (過去 30 日間)
hans
hans 2022 年 11 月 21 日
回答済み: Steven Lord 2022 年 11 月 21 日
I find it highly confusing that the date identifier in the commands datetime and datestr use contrasting meanings for upper case and lower case:
In the description of the datestr format , one finds the format identifier for
  • minutes is MM
  • months is mm
  • seconds is SS
In the description of the datetime format, one finds the format identifier for
  • minutes is mm
  • months is MM
  • seconds is ss

採用された回答

Steven Lord
Steven Lord 2022 年 11 月 21 日
That's correct. This is mentioned in the description of the Format property on the datetime documentation page.
If I recall correctly the specifiers in datenum predate the creation of the Unicode Technical Standard linked in that section of the documentation while the specifiers in datetime conform to that industry standard.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeDates and Time についてさらに検索

製品


リリース

R2021b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by