Skip to content
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

Fix Update0430 #222

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

JohannMaierhofer
Copy link

@JohannMaierhofer JohannMaierhofer commented Apr 30, 2024

In Update0430 hatte ich eine Spalte buchungsart zur Tabelle Konto hinzugefügt.
Diese ist ein Foreign Key in die Buchungsart Tabelle. Die Erzeugen der Foreign Keys in der Tabelle hatte ich vergessen und habe den Update korrigiert.

Der Code wurde analog zu Update0399 implementiert, bis auf "SET NULL" .

PS: Das Problem aus #208 wird damit aber nicht behoben.

@JohannMaierhofer
Copy link
Author

JohannMaierhofer commented Apr 30, 2024

Ich habe das Problem mit dem späteren Erzeugen der späteren Foreign Keys gelöst. Es geht wenn man im DB Kommando eine NOCHECK anhängt. Ich werde das noch separat implementieren, dann auch mit IF NOT EXISTS, damit es nur dann passiert wenn der Key noch nicht existiert.

Und der Grund warum es ohne NOCHECK schief ging war, dass ich bereits eine ID einer Buchungsart in der Konto Tabelle hatte aber die Buchungsart gelöscht hatte. Damit hat der referenzierte Eintrag nicht existiert und der Request wurde korrekt abgewiesen.

@JohannMaierhofer JohannMaierhofer changed the title Fix Update030 Fix Update0430 May 3, 2024
@dippeal dippeal added the fix This will fix a bug label May 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix This will fix a bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants