depends_on
function in your migration and check for the migration which added that columnbecause reasons.
Sajaki wrote: ↑Sun Jun 17, 2018 10:32 am hi,
in Umil we used to have a handy way of checking if a column exists.
https://wiki.phpbb.com/Umil.table_column_exists
does this exist for extension migrations ?
Code: Select all
if ($this->db_tools->sql_column_exists($this->table_prefix . 'users', 'extracolumn'))
{
// code here
}
Obviously, but if you can tell what those reasons are we will be in a better position to help you. If you don't want to give your reasons and have help, then fine - but you will be on your own.
sql_column_exists
for specific conversion cases, eg. phpBB3/phpbb/db/migration/data/v310/passwords_convert_p1.php
https://github.com/phpBB-Studio/DateTop ... ma.php#L18Sajaki wrote: ↑Sun Jun 17, 2018 12:38 pmSajaki wrote: ↑Sun Jun 17, 2018 10:32 am hi,
in Umil we used to have a handy way of checking if a column exists.
https://wiki.phpbb.com/Umil.table_column_exists
does this exist for extension migrations ?Code: Select all
if ($this->db_tools->sql_column_exists($this->table_prefix . 'users', 'extracolumn')) { // code here }