Problems with schema other than the default 'public' #546
Unanswered
fabioselau077
asked this question in
Bugs
Replies: 1 comment
-
|
I agree the core problem is that morph_name is being used for two different concerns:
With a schema-qualified value like core.taggables, the query builder can interpret core as an alias, which leads to the missing FROM-clause error you’re seeing. Since this is currently a Discussion (and I can’t open a PR directly from here), I propose we track it as an Issue / change request with a concrete implementation plan:
Hope this helps. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello, is there any known issue with customizing the schema? I needed to leave it in a different schema than the default public one, but apparently it converts to "core."taggables" instead of "core.taggables" which ends up breaking all the queries.
For example:
SQLSTATE[42P01]: Undefined table: 7 ERROR: missing FROM-clause entry for table "core" LINE 1: select * from "core"."taggables" where "core"."taggable_id" ... ^ (Connection: pgsql, SQL: select * from "core"."taggables" where "core"."taggable_id" = 7 and "core"."taggable_type" = Models\News)By modifying the function below I can now resolve the issue, but I don't know if the best way would be to open a PR, or create a new key in the 'schema' config.
HasTags.php
Beta Was this translation helpful? Give feedback.
All reactions