Tutorials

Basics of ANSI SQL


SQL Table


Data is stored as records in database in the form of table(s).

Important points 

  • A database system is collection of multiple tables.
  • Each table contains rows and columns which contains data. 
  • Each row of the table is called record.
  • Sql queries are written to insert, update, delete or manipulate the record from these tables of the database.
  • Each table may be linked to other table through the primary key.

Example

Students
Id Name Stream
01 Mukesh IT
02 Rajneesh CSE
03 Puja FT
04 Simmi BHMS
05 Anup ME

Read the table given above and answer:

 

What is the table Name?

Students

 

What are the different colomns?

Id, Name and Stream

 

What are the different rows?

01, Mukesh, IT  is the 1st row.

02, Rajneesh, CSE is the 2nd row.

03, Puja, FT is the 3rd row

04, Simmi, BHMS is the 4th row

05, Anup, ME is the 5th row

 

In SQL, we can:

  • create table
  • drop table
  • delete table
  • truncate table
  • rename table
  • alter table
  • update table

We will read about each of these operation in upcoming chapters.



Please Share this page
Views : 206
Like every other website we use cookies. By using our site you acknowledge that you have read and understand our Cookie Policy, Privacy Policy, and our Terms of Service. Learn more Got it!