Warum wird bei "Database Viewer" von allein das Jahr 1899-11-30 angezeigt?
Автор: Tobias M.
Просмотрено 728,
Подписчики 1,
Размещенный 0
Wenn ich in der Datenbank die Spalte auf "Date" formatiere, dann erfolgt eine automatische Anzeige 1899-11-30. Das Datum ist jedoch nicht in der Datenbank gespeichert. Wenn ich also eine andere Spalte aktualisiere ohne das Datum auf 0000-00-00 zu setzen, speichert er mir dieses Datum 1899-11-30 in die Datenbank.
Warum? Wie kann ich das vermeiden?
Danke!
Размещено
Hello Tobias
I apologize but I am not sure I fully understand the situation.
The Database Viewer Object, when you insert a date in a column Date in the Database, does it display correctly?
Is the issue only happening when you change it?
Can you perhaps attach a few screenshots displaying the steps you're taking so I may better understand this?
I remain available here
Stefano
GOOGLE TRANSLATE ---
Hallo Tobias
Ich entschuldige mich, bin mir aber nicht sicher, ob ich die Situation vollständig verstehe.
Wird das Datenbank-Viewer-Objekt korrekt angezeigt, wenn Sie ein Datum in eine Spalte „Datum“ in der Datenbank einfügen?
Tritt das Problem nur auf, wenn Sie es ändern?
Können Sie vielleicht ein paar Screenshots anhängen, die die Schritte zeigen, die Sie unternehmen, damit ich das besser verstehe?
Ich bleibe hier verfügbar
Stefano
Автор
Hello Stefano,
I appreciate your response.
I've encountered a situation where, when I insert a date into this object, it displays the date correctly. However, my issue arises when there is no date entered, as it displays "1899-11-30."
To provide some context, the column is formatted with the date "0000-00-00" in my database (specifically in phpMyAdmin using MySQL). When no date is entered, it should display as "0000-00-00" in the date column. However, the database viewer is showing "1899-11-30" in such cases.
To work with other data in the table using the database viewer, I'm required to delete this date entry first to ensure that "1899-11-30" isn't inadvertently added to the database.
It's worth noting that the "Eintritt" column (as visible in the attachment) is formatted as text, and this particular date doesn't appear in that column.
Thank you for your assistance.
Hello Tobias
I've verified this issue with the developers and I can confirm that this happens due to how Databases work.
In some Databases, since 0000-00-00 isn't a valid date, it gets automatically converted from the Database to a default date. The only way to work around this would have the Database Viewer always send a valid date instead. So if you're filling in this table via a Contact Form or similar, you would need to enforce a valid date to be inserted.
Of course this automatic conversion isn't performed by the Database if the date is valid
I remain available here
Stefano