QuestionQ27
Setup/configuring Adobe Commerce CloudThe developer must convert the module’s database scripts from legacy install/upgrade setup files to the data-patch format and does not want to apply database changes that the install/upgrade scripts already performed.
The current module version is 1.5.4.
What is the recommended solution for skipping changes that were already applied through the old-format install/upgrade scripts?
- A Implement PatchVersionInterface and return 1.5.4 on the getVersion() method.
- B Inside apply() method, check for module version and run the code if version is less than 1.5.4.
- C This is not possible. A module cannot implement both data patch and install scripts.
Community Discussion