Sage X3 provides an inbuilt function to retrieve the number and name of month from the particular date. Following are the functions you need to write for the same.
- To retrieve number of month from given date:
- To retrieve name of month from given date or given number of month:
exp_date : date type expression
exp_num : numerical expression
month$ : extracts the name of the month for a valid date.
If the argument is numerical, it is a month number, calculated with modulo 12 (1 for “January”, etc.).
The result is a Char type.
You can pass either the date or number of a month as an argument to this function.
Refer the below screenshots better understanding.
Here, the date is passed as an argument to month$() function.
Here, the number of a month is passed as an argument to month$() function.
Output for above two snippets is:
Hope this blog helps!
Greytrix is one stop solution provider for Sage ERP and Sage CRM needs. We provide complete end-to-end assistance for your technical consultations, product customizations, data migration, system integrations, third party add-on development and implementation expertise.
Greytrix have some unique solutions of Sage X3’s integration with Sage CRM, Salesforce.com and Magento eCommerce. It also offers best-in-class Sage X3 customization and development services to Sage business partners, end users, and Sage PSG worldwide.
For more information on Sage X3 Integration and Services, please contact us at firstname.lastname@example.org .We will be glad to assist you.
Other Related Blogs: