Re: Because you guys/gals/girls/women/insert pc term hereare a smart lot

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This would be the winning answer.  I've been using text up till now.  I'll 
have to change that.

Thank you!

"Robert Cummings" <robert@xxxxxxxxxxxxx> wrote in message 
news:1231185251.22224.2.camel@xxxxxxxxxxxx
> On Mon, 2009-01-05 at 19:15 +0000, Stuart wrote:
>> 2009/1/5 Frank Stanovcak <blindspotpro@xxxxxxxxxxx>:
>> > It's been a while since I've programed (VB was on version 4) I was 
>> > wondering
>> > if any one could tell me what the diff is between char, varchar, and 
>> > text in
>> > mysql.
>> > I know this isn't a mysql news group, but since I am using php for the
>> > interaction it seemed like the place to ask.  Thanks in advance, and 
>> > have a
>> > great day!
>>
>> char: the space required for the length of the field is allocated for
>> each row no matter how much of it is used.
>>
>> varchar: only the space required for the content of the field is
>> allocated per row but these fields are limited to 255 chars (IIRC) in
>> length.
>>
>> text: for all intents and purposes these have unlimited length (4GBish 
>> IIRC).
>>
>> There is a page in the MySQL manual that explains all of the data
>> formats. Google for mysql data formats and you'll likely get it.
>
> It's generally worth mentioning that you can usually index char or
> varchar, but not text.
>
> Cheers,
> Rob.
> -- 
> http://www.interjinn.com
> Application and Templating Framework for PHP
> 



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux