You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
My Rails/Devise User table is "user", which seems to be a reserved word for Postgres, and rails_admin generates the following SQL
SELECT "user".* FROM "user" ORDER BY user.updated_at desc LIMIT 1
without quoting the ORDER BY "user", which results in the error given in the subject line. The rest of the error message is
PG::SyntaxError: ERROR: syntax error at or near "." LINE 1: SELECT "user".* FROM "user" ORDER BY user.updated_at desc ... ^ : SELECT "user".* FROM "user" ORDER BY user.updated_at desc LIMIT 1
Yeah, thanks, I thought of that, but I'd have to change my whole application, so it is not my first choice. Do you happen to know whether the lack of table name quoting in the ORDER BY clause is a rails_admin problem or an ActiveRecord problem?
My Rails/Devise User table is "user", which seems to be a reserved word for Postgres, and rails_admin generates the following SQL
without quoting the ORDER BY "user", which results in the error given in the subject line. The rest of the error message is
and the error happens here:
The text was updated successfully, but these errors were encountered: