[Bioperl-l] description length
Hilmar Lapp
lapp@gnf.org
Fri, 18 Oct 2002 11:19:26 -0700 (PDT)
In Bio::DescribableI we say
description
Title : description
Usage : $string = $obj->description()
Function: A text string suitable for displaying to the user a
description. This string is likely to have spaces, but
should not have any newlines or formatting - just plain
text. The string should not be greater than 255
characters
and clients can feel justified at truncating strings at
255
characters for the purposes of display
Returns : A scalar
Bio::PrimarySeq::desc is mapped to this. However, some descriptions in
Swissprot are longer than 255 chars. (I'm realizing this while being
thrown out by Oracle while loading swissprot/bioperl-db; MySQL just
silently truncated it.)
Are we happy with this possible truncation (i.e., strict DescribableI
enforcement)? I'll open up the column width (becomes a TEXT in MySQL) in
biosql; my point is rather to point out that the above definition doesn't
play well with factual data when you want to round-trip and have an
enforcing implementation (could be your schema) somewhere in the chain.
What would the problem with relaxing the field width or removing it
entirely?
-hilmar
--
-------------------------------------------------------------
Hilmar Lapp email: lapp@gnf.org
GNF, San Diego, Ca. 92121 phone: +1-858-812-1757
-------------------------------------------------------------