creating textarea field via API

I'm creating a field via API. However, on the Sugar documentation, there's no sample that shows text area -- Creating an Installable Package that Creates New Fields - SugarCRM Support Site

Are there any guidelines for this? Do I use varchar? How do I define rows and column if that's the way? I tried but I am getting MySQL error

Parents
  • Not varchar but text, no max_size,...

            //Long Text
            array(
                'name' => 'long_text_field_example_c',
                'label' => 'LBL_LONG_TEXT_FIELD_EXAMPLE',
                'type' => 'text',
                'module' => 'Accounts',
                'help' => 'Long Text Field Help Text',
                'comment' => 'Long Text Field Comment Text',
                'default_value' => '',
                'rows' => 6,
                'cols' => 80,
                'required' => false, // true or false
                'reportable' => true, // true or false
                'audited' => false, // true or false
                'importable' => 'true', // 'true', 'false', 'required'
                'duplicate_merge' => false, // true or false
            ),
    		
    //    no max_size !!!	

    Perhaps you have to call Quick Repair & Rebuild after the installation if it does not work.

    Harald Kuske
    Principal Solution Architect – Professional Services, EMEA
    hkuske@sugarcrm.com
    SugarCRM Deutschland GmbH

Reply
  • Not varchar but text, no max_size,...

            //Long Text
            array(
                'name' => 'long_text_field_example_c',
                'label' => 'LBL_LONG_TEXT_FIELD_EXAMPLE',
                'type' => 'text',
                'module' => 'Accounts',
                'help' => 'Long Text Field Help Text',
                'comment' => 'Long Text Field Comment Text',
                'default_value' => '',
                'rows' => 6,
                'cols' => 80,
                'required' => false, // true or false
                'reportable' => true, // true or false
                'audited' => false, // true or false
                'importable' => 'true', // 'true', 'false', 'required'
                'duplicate_merge' => false, // true or false
            ),
    		
    //    no max_size !!!	

    Perhaps you have to call Quick Repair & Rebuild after the installation if it does not work.

    Harald Kuske
    Principal Solution Architect – Professional Services, EMEA
    hkuske@sugarcrm.com
    SugarCRM Deutschland GmbH

Children