25
Views
7
Comments
Solved
I have a question regarding date data aggregation

Hello, I want to draw Line Chart based on the Registration Date, but the current data has time data and it is written in Line Chart by the hour. How do I make the Registration Date of the aggregate come out in yyMMdd format only?


스크린샷 2024-12-07 142034.png
2024-12-02 13-16-47
Vipin Yadav
Solution

Hi @Alfana,

Please format the date when binding data (DataPointList). I have attached a screenshot for your reference. 

Please send me your OML file, and I will make the necessary changes for you. 

Thanks,

Vipin Yadav


UserImage.jpg
Alfana

Hello, thank you very much for your response. Based on the information provided, I was able to confirm that the LineChart is separated by date. However, I have noticed that the count in the Aggregate stage is still based on time intervals. I attempted to use the same method of adding a filter within the Aggregate stage using FormatDateTime and DateTimeToDate, but it did not work. 


I apologize for any inconvenience, but as the file size exceeds the limit, I am unable to attach the OML file. 

스크린샷 2024-12-07 143855.png
스크린샷 2024-12-07 144943.png
2024-12-02 13-16-47
Vipin Yadav


You can include a date picker and refresh the aggregate when the date picker's value changes.

In the aggregate filter, you can use the following conditions:

If( RegistrationDate <> NullDate(), DateTimeToDate(Sample_Accounts.CreatedOn) = FormatDateTime(RegistrationDate, "yyyy-MM-dd"), True ) 

 

Thanks,

Vipin Yadav

2024-12-02 13-16-47
Vipin Yadav

I have added oml file for your reference. Please check -

Demo Url - https://vyadav.outsystemscloud.com/FrontEnd/LineChart

Thanks,

Vipin Yadav

FrontEnd.oml
UserImage.jpg
Alfana


Hello,


I received a great deal of help in solving the problem with the answer you provided. Thank you very much.


Alfana

2019-01-07 16-04-16
Siya
 
MVP
Solution

Please follow the below steps

  1. Create a New Attribute in your aggregate "RegDate" with the formula NewDate(Year(UserRegistrations.RegistrationDate),Month(UserRegistrations.RegistrationDate),Day(UserRegistrations.RegistrationDate)) . where UserRegistrations - Your Entity and RegistrationDate - registration Date
  2. Now Group RegDate and Count on Id field. This will give you two attributes Count & RegDate.
  3. OnAfterFetch assign the aggregate List Data Points ( Value = Count and label = RegDate )

UserImage.jpg
Alfana

Hello,

Thank you very much for your help. Your response has solved the problem I was facing.

Best regards,

Alfana

2024-12-02 13-16-47
Vipin Yadav
Solution

Hi @Alfana,

Please format the date when binding data (DataPointList). I have attached a screenshot for your reference. 

Please send me your OML file, and I will make the necessary changes for you. 

Thanks,

Vipin Yadav


UserImage.jpg
Alfana

Hello, thank you very much for your response. Based on the information provided, I was able to confirm that the LineChart is separated by date. However, I have noticed that the count in the Aggregate stage is still based on time intervals. I attempted to use the same method of adding a filter within the Aggregate stage using FormatDateTime and DateTimeToDate, but it did not work. 


I apologize for any inconvenience, but as the file size exceeds the limit, I am unable to attach the OML file. 

스크린샷 2024-12-07 143855.png
스크린샷 2024-12-07 144943.png
2024-12-02 13-16-47
Vipin Yadav


You can include a date picker and refresh the aggregate when the date picker's value changes.

In the aggregate filter, you can use the following conditions:

If( RegistrationDate <> NullDate(), DateTimeToDate(Sample_Accounts.CreatedOn) = FormatDateTime(RegistrationDate, "yyyy-MM-dd"), True ) 

 

Thanks,

Vipin Yadav

2024-12-02 13-16-47
Vipin Yadav

I have added oml file for your reference. Please check -

Demo Url - https://vyadav.outsystemscloud.com/FrontEnd/LineChart

Thanks,

Vipin Yadav

FrontEnd.oml
UserImage.jpg
Alfana


Hello,


I received a great deal of help in solving the problem with the answer you provided. Thank you very much.


Alfana

2019-01-07 16-04-16
Siya
 
MVP
Solution

Please follow the below steps

  1. Create a New Attribute in your aggregate "RegDate" with the formula NewDate(Year(UserRegistrations.RegistrationDate),Month(UserRegistrations.RegistrationDate),Day(UserRegistrations.RegistrationDate)) . where UserRegistrations - Your Entity and RegistrationDate - registration Date
  2. Now Group RegDate and Count on Id field. This will give you two attributes Count & RegDate.
  3. OnAfterFetch assign the aggregate List Data Points ( Value = Count and label = RegDate )

UserImage.jpg
Alfana

Hello,

Thank you very much for your help. Your response has solved the problem I was facing.

Best regards,

Alfana

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.