/
Create database when install module (5h)
Create database when install module (5h)
Magento 2 has two ways to create Database for module:
Install Schema/Upgrade Schema: https://www.cloudways.com/blog/setup-scripts-in-magento-2/
It is old and already deprecated in lastest Magento. Now, you should use Declarative Schema to add/modify the table in database for your module
Declarative Schema:
https://developer.adobe.com/commerce/php/development/components/declarative-schema/
Exercise:
Create new module, use Declarative Schema to create table with the following schema:
https://developer.adobe.com/commerce/php/development/components/declarative-schema/configuration/
Use Schema Patch to add column: Age, Country to the actor https://developer.adobe.com/commerce/php/development/components/declarative-schema/patches/
, multiple selections available,
Related content
Creating a Module (2h)
Creating a Module (2h)
More like this
Controller (5h)
Controller (5h)
Read with this
How to create supplier profile manually
How to create supplier profile manually
More like this
Model/Resource Model/Collection (1 day)
Model/Resource Model/Collection (1 day)
Read with this
Magento Doc: Prepare Environment and basic business (4 days)
Magento Doc: Prepare Environment and basic business (4 days)
Read with this
Another Technique (2d)
Another Technique (2d)
Read with this