Apri il dataset:
poi fai le assegnazioniAQ1.SQL.Clear;
AQ1.SQL.Add('SELECT docenti.COGNOME, docenti.NOME, '+
'FROM docenti '+
'WHERE NOT(docenti.IdDocPk=1) ');
AQ1.Open;
AQ1.First;
ma nella select i campi IdMatFk, IdClaFk non ci sono, non ti conviene mettere:AQ1.FieldByName('IdMatFk') .AsString:= numId_Materia;
AQ1.FieldByName('IdClaFk') .AsString:=numId_ClasseDoc;
N.codice:select * from docenti where NOT(docenti.IdDocPk=1)

Rispondi quotando