Re: [sqlite] I need help with very complex queries

2009-03-10 Thread Igor Tandetnik
"Yuzem" wrote in message news:22446301.p...@talk.nabble.com > As an example, I have: > tables: > movies genres keywords languages countries etc... > > movies columns: > id title year director etc > > The others are: > id "name of the table" (example: id genres) > > The id in all the tables are

Re: [sqlite] I need help with very complex queries

2009-03-10 Thread Yuzem
Jim Wilcoxson wrote: > > For example, in your query you need to add something like: > and genres.genre = 'drama'. Yes but if I add that I neither get any result: sqlite3 movies.db "select movies.id,title,year from movies,genres,countries,languages,keywords,tags where movies.id = genres.id and m

Re: [sqlite] I need help with very complex queries

2009-03-10 Thread Jim Wilcoxson
You have specified how the movies table relates to the other tables, but you haven't specified any independent selection criteria for any tables. For example, in your query you need to add something like: and genres.genre = 'drama'. For this query, only the movies and genres tables are needed be

[sqlite] I need help with very complex queries

2009-03-10 Thread Yuzem
As an example, I have: tables: movies genres keywords languages countries etc... movies columns: id title year director etc The others are: id "name of the table" (example: id genres) The id in all the tables are the same column that is the id of the movie so that every movie can be many ti