Announcements
No record found.
Hi All,
I have created two fiels i.e. one for storing month and the other one for year. Now, I have to combine both fields in a new one.
How to achieve this ?
Any code suggestion !
Thanks !
What result are you expecting, can you share that too ?
Use DMY2DATE function to convert to date.
A := FORMAT(Month) + FORMAT(Year)
Can you please provide more clarification ? Didn't get your answer.
Date field is not needed. We have to concatenate only month and year fields to a new field.
We have one field for storing month and the other one for storing year. Now, we need to create a new field which will store the month and the year (i.e. by concatenating both the fields).
What are the data types for Month and Year, and the new field? As Teddy mentioned Just use the Format function to convert month and Year to string and concatenate using + and assign to your new field.
You need to provide the full requirement and what are you planning to do.
For month, I am using 'Option' data type and for Year, it is 'Integer'. What should be the data type for the new field ideally?
My only requirement is to display the the data in month and year format, date is not needed to be mentioned.
Where to use the Format function, in table or in page ? In both places, it is not accepting. VS Code version is 1.37.1
Hi
You can use Text or Code datatype for the new field.
You can concatenate like this
Newfield = FORMAT(Month) + ' - ' + FORMAT(Year);
If my answer helps to resolve your issue, please verify it by clicking Yes
Regards
Avinash B
Under review
Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.
Congratulations to a top community star!
In our never-ending quest to help the Dynamics 365 Community members get answers faster …
Welcome to the next edition of the Community Platform Update. This is a status …
Stay up to date on forum activity by subscribing.