Eigentlich wollte ich was ganz anderes fragen, aber jetzt hackt es schon an einer eigentlich einfachen Sache (aber ich finde keinen Weg raus und wundere mich, weil ich auch früher schon mit SQL a bissl programmiert habe und zumindest das INSERT INTO keine Probleme machte)
Ich habe hier mal eine Tabelle programmiert,
ID ist eben der Schlüssel in Access, PROFIL_ID ist der Respondent…
CREATE TABLE Obst_alt (
ID COUNTER NOT NULL CONSTRAINT constraintName_pk PRIMARY KEY,
PROFIL_ID integer null,
FRAGE integer null,
MERKMAL integer null,
WERT char(20) null
);
Jetzt sollen simpel Werte eingefügt werden:
INSERT INTO Cbst_alt (PROFIL_ID, FRAGE, MERKMAL, WERT) VALUES (1,1,3,’Apfel’);
INSERT INTO Cbst_alt (PROFIL_ID, FRAGE, MERKMAL, WERT) VALUES (1,1,7,’Banane’);
INSERT INTO Cbst_alt (PROFIL_ID, FRAGE, MERKMAL, WERT) VALUES (1,2,1,’Ja’);
INSERT INTO Cbst_alt (PROFIL_ID, FRAGE, MERKMAL, WERT) VALUES (2,1,1,’Pflaume’);
INSERT INTO Cbst_alt (PROFIL_ID, FRAGE, MERKMAL, WERT) VALUES (2,1,4,’Birne’);
INSERT INTO Cbst_alt (PROFIL_ID, FRAGE, MERKMAL, WERT) VALUES (2,1,7,’Banane’);
INSERT INTO Cbst_alt (PROFIL_ID, FRAGE, MERKMAL, WERT) VALUES (2,2,2,’Nein’);
Es funkt aber ned???
an null vs. not null kann es auch ned liegen - ich habe beide versionen ausprobiert (auch wenn ich noch nicht genau weiss, wann man eigentlich null oder not null anwenden soll)
Vielleicht sieht jemand mit anderen Augen das problem, denn eigentlich müsste es so klappen.
Besten Dank
Stefan