Alter database table columns without dropping table Part 67
Link for code samples used in the demo Link for csharp, dotnet basics, mvc and sql server video tutorial playlists In this video, we will discuss, altering a database table column without having the need to drop the table. Let s understand this with an example. We will be using table tblEmployee for this demo. Use the sql script below, to create and populate this table with some sample data. Create table tblEmployee ( ID int primary key identity, Name nvarchar(50), Gender nvarchar(50), Salary nvarchar(50) ) Insert into tblEmployee values( Sara Nani, Female, 4500 ) Insert into tblEmployee values( James Histo, Male, 5300 ) Insert into tblEmployee values( Mary Jane, Female, 6200 ) Insert into tblEmployee values( Paul Sensit, Male, 4200 ) Insert into tblEmployee values( Mike Jen, Male, 5500 ) The requirement is to group the salaries by ge
|