Autor Beitrag
Master-Basti
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 73



BeitragVerfasst: Mo 19.07.04 12:21 
Hallo nochmal!

wisst ihr woran es liegen kann, wenn man eine solche Meldung bekommt ?!

Zitat:

Violation of Primary or Unique Key constraint "PK_Auftraggesamt" on Table AuftragGesamt


Wäre dankbar für Rat....


Gruß

MasterBasti
Udontknow
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 2596

Win7
D2006 WIN32, .NET (C#)
BeitragVerfasst: Mo 19.07.04 14:17 
Du versuchst, einen Primärschlüssel-Wert in einem Datensatz zu speichern, der bereits in einem anderen Datensatz gespeichert ist. Das ist nicht zulässig, da Primärschlüssel per Definition eindeutig sein müssen.

Cu,
Udontknow
Master-Basti Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 73



BeitragVerfasst: Mo 19.07.04 21:06 
Tatsächlich, die AuftragID, die ich einer anderen Tabelle zuweisen wollte, war bereits enthalten, da wird mir einiges klar.

Th@nks

Gruß

MasterBasti
Udontknow
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 2596

Win7
D2006 WIN32, .NET (C#)
BeitragVerfasst: Di 20.07.04 07:57 
Öh, wie jetzt? :shock:

Nein, nein, die ID kommt in derselben Tabelle bereits vor... Es muss übrigens nicht unbdingt der Primärschlüssel sein, es kann sich auch um ein(e) Feld(kombination) handeln, auf der du einen eindeutigen Index erzeugt hast.

Cu,
Udontknow
Master-Basti Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 73



BeitragVerfasst: Di 20.07.04 11:17 
Ja, in der Tabelle, in welche ich einen neuen Eintrag vornehme!
In dem Falle AuftragTableGesamt....
PK (AuftragID) wird übergeben von AuftragTable... PK (ebenfalls AuftragID)
wird aber erzeugt von einem Generator.