The combination of row and column is called
table.Each table has a name.Tables can be defined as the structure which
contains the data in the database.
Syntax of table :
CREATE TABLE table_name
(
column Name1 data_type(size),
column_Name2 data_type(size),
column_Name3 data_type(size),
....
)
Syntax of table :
CREATE TABLE table_name
(
column Name1 data_type(size),
column_Name2 data_type(size),
column_Name3 data_type(size),
....
)
There
are two way to create the table in sql server.
1
Using command
2
Using Wizard.
1 Using Command:
create table Employee
(Sno int,
Name varchar(50),
Address varchar(60),
Mobile_No varchar(10)
)
How to show the table structure or column from database
we'll execute a select command like
select * from Employee
The output will be:
2 Using Wizard
Step 1- open MS sql server and right click on table and click on new table .
Step 2- An empty window will be open.after that write Column name,datatype and allow nulls like below and click on save .it will ask you table name like below write table name and click ok button.
No comments :
Post a Comment