I am trying to use views to access data in a database.
There are a few tables linked to each other (one table links to another which links to two others). I want to obtain the view that joins all the tables.
Instead of creating a MySQL view and identifying it as an entity, I wanted to join the tables via Views.
The second "central" table contains an ID that should contain the user ID.
Joining the central (and also custom) table with the the "built in" user table is no problem.
However, when I try to join the central table with another custom table, I get a syntax error.
I have tried the exact same thing for both joins: Describe the join via $data['my_table']['table']['join'] and describing the relation (i.e. relation key when describing the column).
---
SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') subquery' at line 1
---
Even though I expected it's really basic and a common operation, it seems that there are no real records online about this problem...
Thanks in advance for your replies and advice!
Comments
Comment #1
dawehnerCan you please post the code you use to integrate views with your custom table? I would be suprised if there would not be the problem.
Comment #2
mustanggb commentedClosing this as outdated to tidy up a bit around here. If you're still having problems with the latest release please create a new issue.