1
add columns to mysql table
CGuild1.com > Tips & Tricks > add columns to mysql table

Add new columns to an existing mySql table

Learn how to add columns to an existing mySql table.

Basic add column to the end of a table

ALTER TABLE table_name ADD new_col VARCHAR(60);

Insert the new column after a specific column

ALTER TABLE table_name ADD new_col VARCHAR(60) AFTER col_a;

Make new column the first column ALTER TABLE table_name ADD new_col VARCHAR(60) FIRST;

I am not sure where I found this, but I'm certain it was on the first page of google!
©2024 CGuild1.com