php-db | 2000121

[PHP-DB] Re: [GENERAL] extra spaces From: Brett W. McCoy (bmccoy <email protected>)
Date: 12/14/00

On Thu, 14 Dec 2000, Soma Interesting wrote:

> I'm using PHP & PostgreSQL.
>
> All values called from the database are still padded with extra spaces from
> the column size in the database. Is this normal - I don't remember this
> happening when I was using MySQL. I thought usually the database stripped
> the extra spaces when it retrieved the values.
>
> How do you recommend dealing with this, using a PHP command to strip every
> value from the database - or can I change something in the database to have
> it strip the spaces auto magic like?

Sounds like you are using fixed length strings (char) rather than variable
length strings (varchar).

-- Brett
                                     http://www.chapelperilous.net/~bmccoy/
---------------------------------------------------------------------------
A fool-proof method for sculpting an elephant: first, get a huge block of
marble; then you chip away everything that doesn't look like an elephant.

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-db-unsubscribe <email protected>
For additional commands, e-mail: php-db-help <email protected>
To contact the list administrators, e-mail: php-list-admin <email protected>