Skip to content
Snippets Groups Projects
Commit dbb49145 authored by Patrick Barroca's avatar Patrick Barroca :grin:
Browse files

rel #21694 : reference id between models and their pseudo records defaults no more to 0

parent 01a4746d
Branches
Tags
4 merge requests!1132Hotline#29412 images des articles dans le resultat de recherche,!1120Master,!1071Dev #21694 stop delete notice,!1063Dev #21694 stop delete notice
......@@ -6,8 +6,8 @@ foreach([['table' => 'album', 'id' => 'notice_id'],
['table' => 'sito_url', 'id' => 'id_notice']]
as $params) {
$adapter->query(sprinf('ALTER TABLE `%s` MODIFY `%s` int(11) null default null',
$params['table'], $params['id']));
$adapter->query(sprintf('ALTER TABLE `%s` MODIFY `%s` int(11) null default null',
$params['table'], $params['id']));
$adapter->query(sprintf('UPDATE `%s` SET `%s`=null WHERE `%s`=0',
$params['table'], $params['id'], $params['id']));
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment