Jump to content

SQL Change Field Type?

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
2 replies to this topic

#1
TcM

TcM

    Writes binary right handed and hex left handed

  • Members
  • PipPipPipPipPipPipPipPipPip
  • 11,147 posts
I have a table for a website, and the field type is currently Text, but I want to change it to longtext. Anyone can help me please? Keep in mind that SQL is totally new to me. I browsed through phpMyAdmin and Google.. but I didn't find how to do it.


Thanks for your help.

#2
Guest_Jordan_*

Guest_Jordan_*
  • Guests
You have to use the ALTER command:

ALTER TABLE t1 CHANGE a LONGTEXT;

Execute that in the SQL tab on phpMyAdmin.

#3
TcM

TcM

    Writes binary right handed and hex left handed

  • Members
  • PipPipPipPipPipPipPipPipPip
  • 11,147 posts
Thanks.. I would assume that t1 is the table name and that a is the field name?