Hi all,
Is there Any Process to change Int filed to bigint
i am trying to convert case number to biginit.
Hi all,
Is there Any Process to change Int filed to bigint
i am trying to convert case number to biginit.
You could redefine the dbType of the case_number field from int(11) to bigint(20) in the extension framework.
Just create a file e.g. \custom\Extension\modules\Cases\Ext\Vardefs\_override_case_number.php with following content:
<?php $dictionary['Case']['fields']['case_number']['dbType']='bigint(20)'; ?>
The file name starting with "_override" makes sure that this file is read after sugarfield_case_number.php in the second vardef run.
Then you should run a quick repair and rebuild, which offers the following SQL command to be executed:
ALTER TABLE cases modify COLUMN case_number bigint(20) NOT NULL auto_increment;
Remove all the comment and empty lines from the repair window and execute the command.
It takes some time for the database to complete this command.
If you want to be sure execute the quick repair and rebuild again to check whether the changes were executed,
I hope you will not have ans side effects ...
Harald Kuske
Principal Solution Architect – Professional Services, EMEA
hkuske@sugarcrm.com
SugarCRM Deutschland GmbH
You could redefine the dbType of the case_number field from int(11) to bigint(20) in the extension framework.
Just create a file e.g. \custom\Extension\modules\Cases\Ext\Vardefs\_override_case_number.php with following content:
<?php $dictionary['Case']['fields']['case_number']['dbType']='bigint(20)'; ?>
The file name starting with "_override" makes sure that this file is read after sugarfield_case_number.php in the second vardef run.
Then you should run a quick repair and rebuild, which offers the following SQL command to be executed:
ALTER TABLE cases modify COLUMN case_number bigint(20) NOT NULL auto_increment;
Remove all the comment and empty lines from the repair window and execute the command.
It takes some time for the database to complete this command.
If you want to be sure execute the quick repair and rebuild again to check whether the changes were executed,
I hope you will not have ans side effects ...
Harald Kuske
Principal Solution Architect – Professional Services, EMEA
hkuske@sugarcrm.com
SugarCRM Deutschland GmbH