# Migration database schema: explode() error occurred

**URL:** <https://forum.mautic.org/t/migration-database-schema-explode-error-occurred/15794>\
**Category:** Product Support\
**Created:** [August 25, 2020, 7:29am UTC](https://forum.mautic.org/t/migration-database-schema-explode-error-occurred/15794 "2020-08-25T07:29:38Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![anki630](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/anki630/32/3193_2.png) [@anki630](https://forum.mautic.org/u/anki630)\
**Post date:** [August 25, 2020, 7:29am UTC](https://forum.mautic.org/t/migration-database-schema-explode-error-occurred/15794/1 "2020-08-25T07:29:39Z")

</div>

**Your software**  
My Mautic version is:v3.1.0  
My PHP version is: 7.3.21

**Your problem**  
My problem is:  
After upgrading from v.3.0.2(new installed) to v.3.1.0, I can’t migrate the database schema.  
These errors are showing in the log:  
php bin/console mautic:update:apply --update-package=~/webapps/mauticapp/3.1.0-update.zip  
Are you sure you wish to update Mautic to the latest version? yes

The ZIP archive could not be found.  
You have new mail in /var/mail/mauticuser  
mauticuser@ip-172-26-11-254:~/webapps/mauticapp$ php bin/console mautic:update:apply --update-package=3.1.0-update.zip  
Are you sure you wish to update Mautic to the latest version? yes  
Step 4 [----\>-----------------------] Clearing the cache

IMPORTANT: Run the same command again with --finish. For example ‘php bin/console mautic:update:apply --finish’  
mauticuser@ip-172-26-11-254:~/webapps/mauticapp$ php bin/console mautic:update:apply --update-package=3.1.0-update.zip --finish  
Step 1 [-\>--------------------------] Migrating database schema…  
In Version20200422144300.php line 115:

Type error: explode() expects parameter 2 to be string, array given

mautic:update:apply [–force] [-p|–update-package [UPDATE-PACKAGE]] [–finish] [-h|–help] [-q|–quiet] [-v|vv|vvv|–verbose] [-V|–version] [–ansi] [–no-ansi] [-n|–no-interaction] [-e|–env ENV] [–no-debug] [–]   
Steps I have tried to fix the problem:  
Step. enter the following command:  
php bin/console doctrine:migration:migrate

Your database version (5.5.5-10.4.14-MariaDB-1:10.4.14+maria~bionic-log) does not support generated columns. Upgrade at least to 10.2.6 and update `db_server_version` accordingly to get the speed improvements.

```
                Mautic Migrations                    

```

WARNING! You are about to execute a database migration that could result in schema changes and data loss. Are you sure you wish to continue? (y/n)y  
Migrating up to 20200815153711 from 20200302164801

++ migrating 20200422144300 (Migrate mautic\_lead\_fields.properties to simple array)

Migration 20200422144300 failed during Execution. Error explode() expects parameter 2 to be string, array given

In Version20200422144300.php line 115:

Type error: explode() expects parameter 2 to be string, array given

doctrine:migrations:migrate [–write-sql [WRITE-SQL]] [–dry-run] [–query-time] [–allow-no-migration] [–all-or-nothing [ALL-OR-NOTHING]] [–configuration [CONFIGURATION]] [–db-configuration [DB-CONFIGURATION]] [–db DB] [–em EM] [–shard SHARD] [-h|–help] [-q|–quiet] [-v|vv|vvv|–verbose] [-V|–version] [–ansi] [–no-ansi] [-n|–no-interaction] [-e|–env ENV] [–no-debug] [–] []

---

<div class="post-metadata">

**Author:** ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)\
**Post date:** [September 27, 2021, 1:51pm UTC](https://forum.mautic.org/t/migration-database-schema-explode-error-occurred/15794/2 "2021-09-27T13:51:26Z")

</div>

Here is what I did (no idea what the long term effect is, but mautic works for now.)

EDIT  
`app/migrations/Version20200422144300.php`  
Change line 115 from  
`$propertyList = explode('|', $properties['list']);`  
to  
`$propertyList = $properties['list'];`

Good luck.
