Drop Down MenusCSS Drop Down MenuPure CSS Dropdown Menu

Thursday 21 September 2017

Creating table in SQL Server


In this article, we have prepared queries to design database and table.



We have designed this table as per our need to create SSRS report.

--Creating database
create database MySchoolDB

--Using database
use MySchoolDB
Go

--Creating table
create table tblTeacher
(
TeacherCode int identity(1,1) primary key,
TeacherName varchar(50),
Address varchar(50),
City varchar(50),
State varchar(50),
Pincode varchar(6),
Designation varchar(50),
DOB varchar(10),
AdditionalInformation varchar(300),
Salary money,
CurrDate varchar(10),
Remarks varchar(100)
)

--Inserting records in table
insert into tblTeacher(TeacherName,Address,City,State,Pincode,Designation,
DOB,AdditionalInformation,Salary,CurrDate,Remarks)
values('Vijay Singh','Sector-100, H.No-1000, ABC Society, XYZ Nagar','Nirman Vihar',
'Delhi','100000','Head PE Coach','21-09-1979',
'Vijay Singh holds a BPE in Physical Education from Delhi University. He was assigned this job in 2003 as Assistant PE Coach.',
70000.00,'21-09-2017','This is system generated report.')

--Retrieving records from table
select * from tblTeacher



Use above records in our following SSRS Reporting article series.


For any query, comment us below.



Click imagination hunt to read latest blogs.



Keep learning and sharing...

No comments:

Post a Comment

Featured post

Think that makes you rich and richer

 Napolean said: “You can think and grow rich, but if you can be brought up like most people with work and you won't starve, this wil...