SQL SELECT multiple INNER JOINs
- by Noam Smadja
The SELECT statement includes a reserved word or an argument name that is misspelled or missing, or the punctuation is incorrect
its Access database..
i have a Library table, where Autnm Topic Size Cover Lang are foreign Keys
each record is actually a book which has its properties such as author and stuff. i am not quite sure i am even using the correct JOIN.. quite new with "complex" SQL :)
SELECT Library.Bknm_Hebrew, Library.Bknm_English, Library.Bknm_Russian, Library.Note, Library.ISBN, Library.Pages, Library.PUSD,
Author.ID AS [AuthorID], Author.Author_hebrew AS [AuthorHebrew], Author.Author_English AS [AuthorEnglish], Author.Author_Russian AS [AuthorRussian],
Topic.ID AS [TopicID], Topic.Topic_Hebrew AS [TopicHebrew], Topic.Topic_English AS [TopicEnglish], Topic.Topic_Russian AS [TopicRussian],
Size.Size AS [Size],
Cover.ID AS [TopicID], Cover.Cvrtyp_Hebrew AS [CoverHebrew], Cover.Cvrtyp_English AS [TopicEnglish], Cover.Cvrtyp_Russian AS [CoverRussian],
Lang.ID AS [LangID], Lang.Lang_Hebrew AS [LangHebrew], Lang.Lang_English AS [LangEnglish],
FROM Library
INNER JOIN Author ON Library.Autnm = Author.ID
INNER JOIN Topic ON Library.Topic = Topic.ID
INNER JOIN Size ON Library.Size = Size.ID
INNER JOIN Cover ON Library.Cover = Cover.ID
INNER JOIN Lang ON Library.Lang = Lang.ID
Thx in advance