MySQL Forums
Forum List  »  German

Re: Fehler beim Erstellen des Fremdschlüssels
Posted by: Jens Kraska
Date: February 05, 2013 01:11AM

Hej Thomas,

gerne


ain_status
CREATE TABLE `ain_status` (
`idAIN_Status` int(10) unsigned NOT NULL AUTO_INCREMENT,
`AIN` varchar(13) NOT NULL,
`Datum` date NOT NULL,
`Bestandsart` int(10) DEFAULT NULL,
`Halle` int(10) DEFAULT NULL,
PRIMARY KEY (`idAIN_Status`),
KEY `Bestandsart` (`Bestandsart`),
KEY `Halle` (`Halle`),
KEY `AIN` (`AIN`),
CONSTRAINT `ain_status_ibfk_1` FOREIGN KEY (`Bestandsart`) REFERENCES `bestandsart` (`idBestandsart`) ON DELETE CASCADE ON UPDATE CASCADE,
CONSTRAINT `ain_status_ibfk_3` FOREIGN KEY (`Halle`) REFERENCES `halle` (`idHalle`) ON DELETE CASCADE ON UPDATE CASCADE
) ENGINE=InnoDB AUTO_INCREMENT=11673673 DEFAULT CHARSET=latin1



und Nr. 2 (ich hab die tabelle ain (hier soll ja auch referenziert werden) genommen, lageralter ist die datenbank)

ain
CREATE TABLE `ain` (
`idAIN` varchar(13) NOT NULL,
`SKU` varchar(20) NOT NULL,
`Unterartikel` varchar(255) DEFAULT NULL,
`WE-Datum` date NOT NULL,
PRIMARY KEY (`idAIN`),
KEY `SKU` (`SKU`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1

Viele Grüße
Jens

Options: ReplyQuote


Subject
Views
Written By
Posted
Re: Fehler beim Erstellen des Fremdschlüssels
993
February 05, 2013 01:11AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.