Filter on Birth Date

I have searched this forum and been uable to find anything on how to do this. In 3.70 Human Resources there is a report called Employee - Birthdays. I have set the DataItemTableView property to SORTING(Birth Date) so the report is sorting by birthday. How do I get it to sort by month instead of year? Thanks in advance.

you can do a string operation on the date value, retrieve the month value out, and do a sortýng again. Good luck

You will need to either create a new field, or somehow else use the month Number := DATE2DMY(Date, What) The function, could be use to MonthNo := DATE2DMY("Birth Date",2); ----8<----8<----- DATE2DMY Returns the day, month, or year based on a date. Number := DATE2DMY(Date, What) Number Data type: integer The day, month, or year of Date. Date Data type: date The input date. What Data type: integer This tells the system what the function should return. The valid options are 1, 2, and 3. This value… Corresponds to… 1 Day (1-31) 2 Month (1-12) 3 Year Example This example shows how to use the DATE2DMY function. d := TODAY; day := DATE2DMY(d,1); month := DATE2DMY(d,2); year := DATE2DMY(d,3); MESSAGE(Text000,day,month,year); Create the following text constant in the C/AL Globals window: Text Constant ENU Value Text000 ‘Today is day %1 of month %2 of the year %3’ The message window could show: Today is day 16 of month 2 of the year 1996 ----8<----8<-----

or you might want to use a temporary variable, running through each day of the respective period and saving the respective employees in a temporary record variable, which you print in a second dataitem. Saludos Nils

Hi for sorting on month first use :=DATE2DMY(Date, 2) 2-> returns the month from the date & then perform the sorting i hope that this will work. thanks ashish