Programming Pandit

c/c++/c#/Javav/Python


Latest Update

Wednesday, December 2, 2020

SQL Queries for Fetch, Update, delete the data by G Krishna Chauhan

Source Code

 CREATE A TABLE:

 

create database EDUCATION ;


CREATE TABLE STUDENT (admn_no int primary key, sname varchar(30), gender char(1), DOB date, stream varchar(15), marks float(4,2))")


INSERT THE DATA

insert into student values (%s, %s, %s, %s, %s, %s)", (1245, 'Arush', 'M', '2003-10-04', 'science', 67.34)


FETCH THE DATA

 

select * from student


UPDATE THE RECORD

 

update student set marks=55.68 where admn_no=1;


DELETE THE DATA

delete from student where admn_no=1




No comments:

Post a Comment