[thelist] Change mySql field size

Anthony Ettinger apwebdesign at yahoo.com
Wed Sep 7 19:12:35 CDT 2005


ALTER TABLE foo MODIFY column FOO ...

I would just use TEXT or TINYTEXT but if you wanted
only 1000 chars, you would use VARCHAR(1000);





--- Bernardo Escalona-Espinosa <escalonab at gmail.com>
wrote:

> Hello list,
> 
> I feel really dumb by asking this, but I just need
> to be sure.
> 
> I need to change the size of a field in one of my
> mySql databases.
> Right now i only allow visitors to my website to add
> comments that are
> 300 chars long, and i want to allow up to 1000.
> 
> 1) I couldnt find a definite answer but i think the
> mySql command goes
> something like this:
> ALTER TABLE comments CHANGE comment_content
> text(1000);
> Does this look ok? Im still not very clear on the
> maximum size and
> trailing-space removal of TEXT-type fields.
> 
> 2) Will the existing contents of these fields be
> affected? My guess is
> probably not, but I just want to make sure.
> 
> -- 
> ___________________________________________
> Bernardo Escalona Espinosa
>   office: [52 55] 56 22 85 23
>   fax:  [52 55] 56 22 88 77
>   home: [52 55] 55 30 13 96
>   cel: 55 18 56 74 73
>   http://www.bernsonline.com/
> --
> 
> * * Please support the community that supports you. 
> * *
> http://evolt.org/help_support_evolt/
> 
> For unsubscribe and other options, including the Tip
> Harvester
> and archives of thelist go to:
> http://lists.evolt.org
> Workers of the Web, evolt !
> 


Anthony Ettinger
ph: (408) 656-2473
blog: http://www.chovy.com

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


More information about the thelist mailing list