How to Alter Table in SQL Server by using Alter Statement - SQL Server / TSQL Tutorial Part 35. SQL Server / TSQL Tutorial Scenario: How to Alter Table in SQL Server by using Alter Statement
Let's say that you are working as SQL Server developer in Mortgage Company. In TechBrotherIT database, there is Dbo.Customer Table with below definition.
Create Table dbo.Customer
(FirstName VARCHAR(50),
LastName VARCHAR(50),
Age TinyInt,
PhoneNumber CHAR(9),
DOB Date,
Sex CHAR(1)
)
You got the requirement in which you have to generate Alter statement for below changes
Add Column Address to Customer Table
Modify column FirstName data type from VARCHAR(50) to VARCHAR(60)
Drop Column Age from Customer Table
Link to Scripts used in the video
http://www.techbrothersit.com/2016/02/how-to-alter-table-in-sql-server-by.html
Check out our website for Different SQL Server, MSBI tutorials and interview questions
such as SQL Server Reporting Services(SSRS) Tutorial
SQL Server Integration Services(SSIS) Tutorial
SQL Server DBA Tutorial
SQL Server / TSQL Tutorial ( Beginner to Advance)
http://www.techbrothersit.com/
Tags: How to Alter Table in SQL Server by using Alter Statement - SQL Server / TSQL Tutorial Part 35, Alter table, Add Column, Drop Column, Generate Alter scripts for SQL Deployment, SQL, Server, SQL Server Tutorial, TSQL Tutorial, Transact SQL, SQL Server Free Training, TSQL Free Training, Database, SQL Server Free Video Tutorial, TSQL Video Free Training, Step by Step SQL Server Tutorial for beginners to advance level, SQL Developer, SQL Interview Questions, Real time Interview Questions for SQL Server Developer or DBA, TechBrothersIT, MSBI, Real time SQL Scripts