SitePoint Sponsor

User Tag List

Results 1 to 2 of 2

Hybrid View

  1. #1
    Member ngaisteve1's Avatar
    Join Date
    May 2003
    Location
    Kuala Lumpur, Malaysia (Boleh!)
    Posts
    264
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Mysql: Change the sequence of the db field for readability purpose

    When we go to database structure, we see those db field row by row, isn't? I wonder if there is any way for me to change the sequence of my database field. The purpose for me to change the sequence is for readability purpose.

    Thanks.

  2. #2
    Chessplayer kleineme's Avatar
    Join Date
    Apr 2004
    Location
    Germany
    Posts
    608
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi,

    create a new table with the desired sequence of columns and then copy the old data into the new table. You may use CREATE TABLE ... SELECT to do that in one step.
    Never ascribe to malice,
    that which can be explained by incompetence.
    Your code should not look unmaintainable, just be that way.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •