Hello,
I am new to outsystems. I want to group my data aggregate by Month. What I did so far is to create a new attribute with the value of Month(ProjectSavings.Month) to assign the month integer value to each data and then grouping the data by the month integer:
However, I would like for it to be group by the name of the month (January/Feburary/March etc...) instead of it being group by integer right now. What can I do to achieve this? Thank you!
Hi @Low Ding En ,You can do it by using the FormatDateTime built-in function. However you cannot use formatdateTime inside an aggregate (as far as i remember, might have changed).So what i recomend you doing is leaving it like you have, but then on your widget on screen where you will be displaying the value, in the expression wherever you want to show the month name, you put the expression value like this:
FormatDateTime(NewDate(2000,MonthByNumber,1),"MMMM")
PS: The values on the new date for year and day doesn't matter, you just want a date with your month so that you can then pass that date to the formatDateTime function, and passing "MMMM", which will return the full month name of that date!Let me know if this helped!Regards,Paulo
Hello Paulo,
Thank you so much for your help! This was what I was looking for!
HelloYou can refer to this post hope this might help
https://www.outsystems.com/forums/discussion/48121/how-to-convert-monthinterger-type-to-stringname-of-month/Best RegardsTousif Khan
Thank you for your suggestion, it was helpful !