Unix Timestam with Date Calculator
-
matt.baile
- Member
- Posts: 52
- Joined: Wed Nov 29, 2017 4:36 pm
Unix Timestam with Date Calculator
I am working on adding a Unix time stamp to a rename a file in one of my workflow. I am using the Date Calculator app from the apps store to do this, and it is working, sort of. Each file I pass through gets the same time stamp, specifically 1787025600 which is Tue Aug 18 2026 00:00:00 GMT-0400 (Eastern Daylight Time)
The problem is that no matter when I drop the file through the workflow, the Unix time stamp is still the same. The app documentation says it does down to the second, but does it not actually adjust to the actual second and only gives you one timestamp per day?
The problem is that no matter when I drop the file through the workflow, the Unix time stamp is still the same. The app documentation says it does down to the second, but does it not actually adjust to the actual second and only gives you one timestamp per day?
Re: Unix Timestam with Date Calculator
As you can see in the settings it calculates dates. Your setting is to count number of days.
There is an option to calculate time. You can try that.
There is an option to calculate time. You can try that.
-
matt.baile
- Member
- Posts: 52
- Joined: Wed Nov 29, 2017 4:36 pm
Re: Unix Timestam with Date Calculator
Thank you - I did try that, but then I don't have access to the newDateTimeNumber private data unfortunately.
Re: Unix Timestam with Date Calculator
It calculate in two different ways, dates or time. But you can add those values with the Switch calculator. First two steps to get the two values and then calculate the two values.
-
matt.baile
- Member
- Posts: 52
- Joined: Wed Nov 29, 2017 4:36 pm
Re: Unix Timestam with Date Calculator
Thank you. I have two lanes in my workflow - one which I'm just naming a file by newDateTimeNumber and one in which I'm doing a calculation as follows:
[Switch.Calculation:Expression="[Job.PrivateData:Key="newDateTimeNumber"]+[Job.PrivateData:Key="newHour"]"]
For the newDateTimeNumber, when I drop a file I get a name of 1787112000
For the calculation, I get a file name of 1787112012
Dropping another file gives me the same result in both lanes, so even though this should be to the second, it appears that I can only go to the hour in SWITCH - is that correct?
Also, I have the "Number of Days" and "Number of Hours" properties set to "0", but when deciphering my values, online calculators point to the time being 12 hours ago. Why would I have to add 12 to "Number of Hours" to get this to calculate correctly - shouldn't this be by default?
Appologies for the questions. This is a new app for me and my first time using the Unix Timestamp.
[Switch.Calculation:Expression="[Job.PrivateData:Key="newDateTimeNumber"]+[Job.PrivateData:Key="newHour"]"]
For the newDateTimeNumber, when I drop a file I get a name of 1787112000
For the calculation, I get a file name of 1787112012
Dropping another file gives me the same result in both lanes, so even though this should be to the second, it appears that I can only go to the hour in SWITCH - is that correct?
Also, I have the "Number of Days" and "Number of Hours" properties set to "0", but when deciphering my values, online calculators point to the time being 12 hours ago. Why would I have to add 12 to "Number of Hours" to get this to calculate correctly - shouldn't this be by default?
Appologies for the questions. This is a new app for me and my first time using the Unix Timestamp.
Re: Unix Timestam with Date Calculator
I will add current time UNIX for a PrivateData value.
It will give you the value down to milli seconds.
It will take a few days for it to go through the approval at Enfocus.
It will give you the value down to milli seconds.
It will take a few days for it to go through the approval at Enfocus.
-
matt.baile
- Member
- Posts: 52
- Joined: Wed Nov 29, 2017 4:36 pm
Re: Unix Timestam with Date Calculator
Wow - that's fantastic! I had no idea you were the actual developer. Thank you! And much appreciation with all of this!!!
Re: Unix Timestam with Date Calculator
The new version of Date Calculator is up now in App Store
-
matt.baile
- Member
- Posts: 52
- Joined: Wed Nov 29, 2017 4:36 pm
Re: Unix Timestam with Date Calculator
Thank you! I updated the install and rebooted, but I'm not able to pick up the UNIX time stamp. Any thoughts on what may be happening? I thought maybe the spaces in the "Current time stamp" was causing problem, so I changed the Value name to UNIX, and that didn't give me a value either.
]
Re: Unix Timestam with Date Calculator
When an app has new properties you have to drag in a new instance of it. Before you remove the old one you can copy the properties from the old one to the new one.
-
matt.baile
- Member
- Posts: 52
- Joined: Wed Nov 29, 2017 4:36 pm
Re: Unix Timestam with Date Calculator
I did that and restarted, but I'm still not getting a timestamp. Could you show a screenshot of the Properties to ensure I have everything set correctly? When I try to rename by the private data, I just do not get a value.
Re: Unix Timestam with Date Calculator
Sorry,
It was a busy week when I did this modification and apparently I missed a vital part.
A new version will be available next week.
It was a busy week when I did this modification and apparently I missed a vital part.
A new version will be available next week.
-
matt.baile
- Member
- Posts: 52
- Joined: Wed Nov 29, 2017 4:36 pm