Hi Teamst,
I have problem with new custom field management,
We have test cases which has test data & Precondition fields where it is above 2000 characters,
Please help me out from this issue.
At present the custom fields are displaying only 250 characters remaining are lost.
Please reply with the steps to resolve this issue.
problem faced in custom fields
Moderators: Amaradana, TurboPT, TL Developers
Q: for TL developers.
I can assist with this question, but should I go through the steps?
What would be the impact [i.e. upgrades] if changes are applied -- as this will be a customized (outside of TL) change? (so that the original poster will be aware)
Also, I will investigate the import handling [the php-side] as well. (to make sure it all goes smoothly at both ends)
I can assist with this question, but should I go through the steps?
What would be the impact [i.e. upgrades] if changes are applied -- as this will be a customized (outside of TL) change? (so that the original poster will be aware)
Also, I will investigate the import handling [the php-side] as well. (to make sure it all goes smoothly at both ends)
This is because database type is string with 256 characters. So, application miss maximal size checking. I didn't develop this feature, so I don't know details. My expectation is that 'text' DB type must be implemented to solve it.
I suggest to add precondition to steps or summary meantime. I expect that in some future version will be added possibility to cutomize structure of TC. There are people looking for step-by-step structure, etc.
I suggest to add precondition to steps or summary meantime. I expect that in some future version will be added possibility to cutomize structure of TC. There are people looking for step-by-step structure, etc.
I need to understand impacts at DB level if we choose to use text column type.
Anyway my vote is leave custom fields as are implemented today (I've have used mantis and dotptoject as model), with a limited (a very limited size) to avoid abuse.
You can do changes in your installation without ANY problem
Anyway my vote is leave custom fields as are implemented today (I've have used mantis and dotptoject as model), with a limited (a very limited size) to avoid abuse.
You can do changes in your installation without ANY problem
Adjusting custom field size limitation
Hi ,
In the current code base (1.8.1) there seems to be 2 locations where the size of the custom text field is determined:
- the database model : Table cfield_design_values, field 'values' which is set to variable char with limit 500
- the file lib/functions/cfield_mgr.class.php in which a variable $max_length_value is set to 255
In other words the database accepts entries until 500 chars, but when using the interface only 255 are saved.
I've modified my own installation to use a database type var char of max 2000 char + also updated the variable
(ALTER TABLE cfield_design_values ALTER COLUMN value TYPE varchar(2000))
Is there any objection to modify the code base to a higher max value as described above? 255 chars is low for a 'text' type custom field ...
In the current code base (1.8.1) there seems to be 2 locations where the size of the custom text field is determined:
- the database model : Table cfield_design_values, field 'values' which is set to variable char with limit 500
- the file lib/functions/cfield_mgr.class.php in which a variable $max_length_value is set to 255
In other words the database accepts entries until 500 chars, but when using the interface only 255 are saved.
I've modified my own installation to use a database type var char of max 2000 char + also updated the variable
(ALTER TABLE cfield_design_values ALTER COLUMN value TYPE varchar(2000))
Is there any objection to modify the code base to a higher max value as described above? 255 chars is low for a 'text' type custom field ...
Re: Adjusting custom field size limitation
Sorry,
Small mistake : the default value for the $max_length_value was already modified on my installation from 255 to 500.
kind regards
Pieter
Small mistake : the default value for the $max_length_value was already modified on my installation from 255 to 500.
kind regards
Pieter
Re: problem faced in custom fields
FYI in TestLink version 1.9.1 I found the following configurable value :
config.inc.php: * 20090823 - franciscom - new option custom_field_max_length
config.inc.php:$tlCfg->custom_fields->max_length = 255;
allowing to set the max length as described in this post. Mind that the database currently (1.9.1 new database ) limits the size to 4000 :
Table "public.cfield_design_values"
Column | Type | Modifiers
----------+-------------------------+----------------------------------------
field_id | integer | not null default 0
node_id | integer | not null default 0
value | character varying(4000) | not null default ''::character varying
config.inc.php: * 20090823 - franciscom - new option custom_field_max_length
config.inc.php:$tlCfg->custom_fields->max_length = 255;
allowing to set the max length as described in this post. Mind that the database currently (1.9.1 new database ) limits the size to 4000 :
Table "public.cfield_design_values"
Column | Type | Modifiers
----------+-------------------------+----------------------------------------
field_id | integer | not null default 0
node_id | integer | not null default 0
value | character varying(4000) | not null default ''::character varying