Describe tablePrefix
use in Migrations (plugin development)
#523
Unanswered
criticalmash
asked this question in
Ideas
Replies: 0 comments
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.
-
In the Migrations documentation there is this line
The docs for migration->insert() say it only takes a string, which gives the impression that it's just the literal name of the table, but this is obviously some sort of template. I'm guessing if the prefix was set to
craft_
the table name would come out ascraft_mytablename
. But I can't be sure of that due to the lack of documentation.This all started when I tried to follow the Element Types documentation. If you're following along you first create a model called
products
then create an Install migration using...I'm guessing that table name should have been
{{%products}}'
Beta Was this translation helpful? Give feedback.
All reactions