I am working with time-related data in Make.com and am trying to calculate the difference between two time fields (Due Date time start (D)
and Due Date time end (E)
) to determine the duration in minutes or hours. However, I am encountering issues with my formula.
Input Data:
- Due Date time start (D):
"7:00:00 PM"
- Due Date time end (E):
"10:00:00 PM"
- Duration: D - E (need better approach to do this
- Other fields: Various date and time-related fields such as Start Date (
November 6, 2024 12:00 AM
) and End Date (November 6, 2024 12:00 AM
).
Issue:
The formula is not working as expected, and it’s creating an event at 12:00 AM - 12:00 AM
instead of calculating the correct time difference. The formula seems to be incorrectly parsing and subtracting parts of the time string, which is leading to this unexpected result.
Could someone help me with the correct approach or formula to calculate the time difference between Due Date time start (D)
and Due Date time end (E)
in minutes or hours? Ideally, I want to calculate the difference based on these time fields directly.
Output from Google Sheets:
- Start:
11/6/2024 19:05:01
- Task Title:
"Latest one"
- Due Date Time Start:
"7:00:00 PM"
- Due Date Time End:
"10:00:00 PM"
I am using these values to create an event, but the calculation for the duration isn’t working properly.
Any help or insights would be greatly appreciated!
Welcome to the Make community!
You should only specify:
Start Date
End Date
or
Start Date
Duration
For more information, see Events: insert | Google Calendar | Google for Developers
If you need further assistance, please provide the following:
1. Relevant Screenshots
Please share screenshots of your scenario, any error messages, relevant module fields, and filters in question? It would really help other community members to see what you’re looking at.
You can upload images here using the Upload icon in the text editor:
2. Scenario Blueprint
Please export the scenario blueprint file to allow others to view the mapped variables in the module fields. At the bottom of the scenario editor, you can click on the three dots to find the Export Blueprint menu item.
3. Output Bundles of Modules
Please provide the output bundles of the modules by running the scenario (or get from the scenario History tab), then click the white speech bubble on the top-right of each module and select “Download input/output bundles”.
A. Upload as Text File
Save each bundle contents in your text editor as a bundle.txt
file, and upload it here into this discussion thread.
B. Insert as Formatted Code Block
If you are unable to upload files on this forum, alternatively you can paste the formatted bundles.
These are the two ways to format text so that it won’t be modified by the forum:
-
Method 1: Type code block manually
Add three backticks ```
before and after the content/bundle, like this:
```
content goes here
```
-
Method 2. Highlight and click the format button in the editor
Providing the input/output bundles will allow others to replicate what is going on in the scenario even if they do not use the external service.
Following these steps will allow others to assist you here. Thanks!
— @samliew
P.S.: Investing some effort into the Make Academy will save you lots of time and frustration using Make.