Re: extra spaces

From: Alex Pilosov <alex(at)pilosoft(dot)com>
To: Soma Interesting <dfunct(at)telus(dot)net>
Cc: php-general(at)lists(dot)php(dot)net, php-db(at)lists(dot)php(dot)net, pgsql-general(at)postgresql(dot)org
Subject: Re: extra spaces
Date: 2000-12-14 22:59:05
Message-ID: Pine.BSO.4.10.10012141758510.5632-100000@spider.pilosoft.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Make your fields to be varchar(x), not char(x)

-alex

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?
>
>
> - - - - - - -
> - - - -
> WARNING: Some experts believe that use of any keyboard may cause
> serious injury. Consult Users Guide.
> dfunct(at)telus(dot)net
>
>

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Sandeep Joshi 2000-12-14 23:04:34 create trigger
Previous Message Soma Interesting 2000-12-14 22:55:34 extra spaces