Add Delete field SQL

Source: Internet
Author: User
General: ALTER TABLE [table name] add [Field name] Field properties default default is optional parameter increment field: ALTER TABLE [table name] Add field name smallint default 0 Add Number field, int, The default value is 0 ALTER TABLE [table name] Add field name int default 0 Add Number field, Long integer, default value 0alter table [table name] Add field name single default 0 Add Number field, one type, default value is 0 a Lter table [table name] Add field name double default 0 Add Numeric field, double type, default value 0alter table [table name] Add field name Tinyint default 0 Increase Number field, byte type, default value is 0 alte R table [table name] Add field name text [NULL] Add Memo field, [NULL] optional parameter ALTER TABLE [table name] Add field name MEMO [NULL] Add Memo Type field [NULL] optional parameter ALTER TABLE [table name ] Add field name varchar (N) [null] increase variable length text type field size N (1~255) ALTER TABLE [table name] Add field name char [null] increase fixed length text field size fix to 255 ALTER TABLE [table name] Add field name the datetime default function increments the Date field, where the function can be now (), date (), and so on, representing the default value (which is most commonly used, and other properties, which can be referenced in the following data type description) Delete field: ALTER TABLE [table name] Drop field name Modify the size of the text Type field: ALTER TABLE [table name] ALTER field name varchar (N) Delete table: Drop tables [table name]

Add Delete field SQL

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.