문제

people. I'm trying to migrate to declarative schema on my module with magento v2.3.1. But when i'm running php bin/magento setup:install --convert-old-scripts=1 it doesn't generates any db_schema.xml. What i'm doing wrong?

도움이 되었습니까?

해결책

Try to remove your module from setup_module table and rerun the command.

As far as I understand, Magento analyzes DDL commands called during setup:upgrade to generate the schema.

In your case, I assume, the legacy install scripts are not being executed.

다른 팁

In order to migrate your install and upgrade schema of already installed module to db_schema.xml follow below steps

  • Remove your module entry from setup_module table
  • Drop all your module tables as mentioned in your install and upgrade schema
  • Execute php bin/magento setup:upgrade --convert-old-scripts=1
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 magento.stackexchange
scroll top