I have a table for polling and you want to delete all records related to one specific page.
My tables:
_______________ _______________ ___________ ________________ |_tblSurvey___| |_tblAnswers___| |_tblAlt__| |_tblQuestions_| | surveyID | | answerAltID | | altID | | questID | | surveyName | | userID | | altText | | questText | |_____________| |______________| |_questID_| |_surveyID_____|
Say I want to delete all entries related to surveyID 1.
I tried:
DELETE * FROM tblSurvey, tblQuestions, tblAlt, tblAnswers WHERE tblSurvey.surveyID = 1 AND tblsurvey.surveyID = tblQuestions.surveyID AND tblQuestions.questID = tblAlt.questID AND tblAlt.altID = tblAnswers.answerAltID
janlindso
source share