user1604294
user1604294

Reputation:

Postgres SQL select query syntax

I have this SQL statement, I am getting a syntax error:

SELECT
  *
FROM
  user_table
  INNER JOIN (
    klass_table
    LEFT JOIN room_table
  )

Syntax error is vague, it says:

You have an error in your SQL syntax; it seems the error is around: ')' at line 8

Perhaps I am missing an ON clause?

Upvotes: 0

Views: 71

Answers (1)

CodeOfLife
CodeOfLife

Reputation: 313

You have not mentioned the columns on which you are doing the inner join.So basically you are missing the "ON" keyword for both the joins.

Upvotes: 1

Related Questions