-
-
Notifications
You must be signed in to change notification settings - Fork 65
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DATETIME truncation #1947
Comments
Same test case on 25.1.1-SNAPSHOT, it does NOT truncate. |
After reading https://docs.arcadedb.com/#Managing-Dates, I noted there's
After incorporating it into docker compose, there's no longer truncation: |
@lvca Maybe I should add an explicit note to the docs? @jymcheong where in the docs would you look first to find such info? @jymcheong can this issue be closed then? |
@gramian the info was under Managing Date section. As for closing, It’s going to be a problem for users who have DATETIME type properties if they didn’t explicitly set that JAVA OPT for docker run or compose. In fact prior to answering this, we were testing it under WSL2 container, same problem. |
I downloaded 25.1.1 tar & ran it on host directly, time truncated: but after I modified bin/server.sh to include That means someone who upgrades from 24 to 25.1.1-SNAPSHOT, to 25.1.1 release, will end up with a surprise like what we encountered, our UI timeline suddenly started to show only dates. Because we have some demo to show soon, I had to dig into the manual to find workarounds. So I am not sure if this should be closed. |
It is not explicitly found in the manual, but based on that ALTER statement, I ported it to docker compose & it worked. That is more like a workaround. 24 to 25.1.1-SNAPSHOT didn't exhibit this behavior. Something changed in 25.1.1 release & it became like this. I upgraded to 25.1.1 because it resolved #1898 |
Checking [...,
{ "key":"arcadedb.dateImplementation","value":"java.util.Date","description":"Default date implementation to use on deserialization. By default java.util.Date is used, but the following are supported: java.util.Calendar, java.time.LocalDate","overridden":false,"default":"java.util.Date"},
{"key":"arcadedb.dateFormat","value":"yyyy-MM-dd","description":"Default date format using Java SimpleDateFormat syntax","overridden":false,"default":"yyyy-MM-dd"},
...] Trying to change the ALTER DATABASE `arcadedb.dateFormat` 'yyyy-MM-dd HH:mm:ss'; as described in the docs, leads to the error:
(This error is unrelated though) |
Also |
OK, more info: The error described above with Using:
makes
has no effect. I will add this effect to the docs. |
@jymcheong as another workaround you can start the ArcadeDB server with an option like |
Something is still off. The workaround above seems only to work if the database is created afterwards (I guess this is expected?). |
@gramian yes, the same observation at my end. Had to drop the DB & create then somehow sysdate() and those test statements will start to run correctly. |
Version: 25.1.1 release docker container
Steps to reproduce
Expected: timestamp = 2025-02-06 06:46:01
Actual: timestamp showing YYYY-MM-DD format
Other notes
arcadedb.dateTimeFormat = yyyy-MM-dd HH:mm:ss
insert into Alert CONTENT { type:'IT', timestamp = "2024-12-05 22:56:02"}
, it still ends up truncating time portiondefault sysdate('YYYY-MM-DD HH:MM:SS')
was taken from arcadeDB docs website, it ends up setting default on arcadeDB UI is showing today's date instead of sysdate, seen that in OrientDB before.The text was updated successfully, but these errors were encountered: