状況をテストしたいのですが、仮説をテストするためにダミーのデータ行を追加する必要があります。したがって、この SELECT INTO の mySQL マニュアル ページによると、私のクエリは正しいです。
SELECT INTO courses.sections_rfip
(SectionID, CourseID, SectionNumber, Term, Credits, CutOffDate, StartDate, EndDate, LastDateToWithDraw, ContinuousIntake, AcceptsRegistration, Fee, Instructor, SectionDescription, RegistrationRestrictions, MeetingTime, Notes, Active, Created, SetInactive)
SELECT 3,
s.CourseID,
s.SectionNumber,
s.Term,
s.Credits,
s.CutOffDate,
s.StartDate,
s.EndDate,
s.LastDateToWithDraw,
s.ContinuousIntake,
s.AcceptsRegistration,
s.Fee,
s.Instructor,
s.SectionDescription,
s.RegistrationRestrictions,
s.MeetingTime,
s.Notes,
s.Active,
s.Created,
s.SetInactive
FROM courses.sections_rfip s
WHERE s.sectionid = 1
しかし、次のエラー メッセージが表示されます。
「SQL 構文にエラーがあります。MySQL サーバーのバージョンに対応するマニュアルで、1 行目の 'INTO course.sections_rfip (SectionID, CourseID, SectionNumber, Term, Credits, ' の近くで使用する正しい構文を確認してください。
つまり、INTO で何かが腐っていますが、その理由は私には明らかではありません - 助けてください。