phpbar.de logo

Mailinglisten-Archive

Leerzeichen verschwindet

Leerzeichen verschwindet

Sebastian Mendel lists at sebastianmendel.de
Don Jun 1 14:08:08 CEST 2006


Norbert Pfeiffer schrieb:
> Hallo Thomas,
> 
>> Ja im Handbuch steht es:
>> If you need a column for which trailing spaces are not removed, consider
>> using a BLOB or TEXT type. If you want to store binary values such as
>> results from an encryption or compression function that might contain
>> arbitrary byte values, use a BLOB column rather than a CHAR or VARCHAR
>> column, to avoid potential problems with trailing space removal that 
>> would
>> change data values.
> hmm,
> hast Du dazu eine Kapitel- oder Abschnitts-Ueberschrift.
> Sonst findet man das ja nie ... <hektisch.rumsuch>

steht direkt bei der Beschreibung zum varchar:

http://dev.mysql.com/doc/refman/5.0/en/char.html

6. Absatz:

"VARCHAR values are not padded when they are stored. Handling of 
trailing spaces is version-dependent. As of MySQL 5.0.3, trailing spaces 
are retained when values are stored and retrieved, in conformance with 
standard SQL. Before MySQL 5.0.3, trailing spaces are removed from 
values when they are stored into a VARCHAR column; this means that the 
spaces also are absent from retrieved values."


ebenso

http://dev.mysql.com/doc/refman/4.1/en/char.html

6. Absatz:

"VARCHAR values are not padded when they are stored. Trailing spaces in 
MySQL version up to and including 4.1 are removed from values when 
stored in a VARCHAR column; this also means that the spaces are absent 
from retrieved values."


-- 
Sebastian

-- 
Infos zur Mailingliste, zur Teilnahme und zum An- und Abmelden unter
-->>  http://www.4t2.com/mysql 


php::bar PHP Wiki   -   Listenarchive