0% found this document useful (0 votes)
4 views2 pages

INDEX11

The document outlines a series of SQL queries related to creating and managing various database tables including Student, Supplier, Employee, Department, and Library. It includes tasks such as displaying specific records, updating data, creating views, and managing indexes. Each section is numbered and contains multiple queries aimed at different functionalities within the database system.

Uploaded by

omermd2021
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views2 pages

INDEX11

The document outlines a series of SQL queries related to creating and managing various database tables including Student, Supplier, Employee, Department, and Library. It includes tasks such as displaying specific records, updating data, creating views, and managing indexes. Each section is numbered and contains multiple queries aimed at different functionalities within the database system.

Uploaded by

omermd2021
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

INDEX

SNO CREATE A STUDENT TABLE AND DISPLAYTOPIC


OUTPUT FOR THE PAGE.NO SIGNATURE
CREATE A SUPPLIER TABLE AND DISPLAY OUTPUT FOR THE
I. FOLLOWING QUERIES:
FOLLOWING QUERIES:

1 Write a SQL query to display supplier numbers and supplier name whose
name starts with ‘R’
2 Write a SQL query to display the name of supplier who supply processors
and whose city is Delhi.
3 Write a SQL query to display the names of suppliers who supply the
same item as supplied by Ramesh
4 Write a SQL query to increase the price of keyboard by 200
5 Write a SQL query to display supplier numbers, supplier names and item
price for suppliers in Delhi in the ascending of item price
6 Write a SQL query to add a new column called contact no
7 Write a SQL query to delete the record whose item price is the lowest of
all the item supplied.
8 Create a view on the table which displays only supplier numbers and
supplier names.
9 Write a SQL query to display the records in the descending order of item
price for each item supplied.
10 Write a SQL query to display the records of suppliers who supply item
other than processor or keyboard
CREATE AN EMP_DETAILS TABLE AND DISPLAY OUTPUT FOR THE
II. FOLLOWING QUERIES:

11 Write a SQL query to display the employees whose designation is


programmer
12 Write a SQL query to display who joined after 2014
13 Write a SQL query to display all the employees whose names ends with
‘a’
14 Write a SQL query to display the total salary of all the employees whose
designation is programmer
15 Write a SQL query to display all the employees names in upper case
16 Write a SQL query to display the details of the employee with highest
experience
17 Write a SQL query to display the details of the employees whose name
contains ‘ee’
18 Write a SQL query to increase the salaries of employees by 5000 whose
designation is DBA
19 Write a SQL query to display the employees whose salary is more than
the average salary of all the employees
20 Write a SQL query to display the record in the following format:
Xxxxxx is working as xxxxx with salary of Rs. Xxxxx
CREATE TWO TABLES (EMPLOYEE AND DEPARTMENT) AND
III. DISPLAY OUTPUT FOR THE FOLLOWING QUERIES:

21 Write a SQL query to display all the employees who earn more than the
average salary of employees in the company
22 Write a SQL query to display the fields Eid, Ename and Dname
23 Write a SQL query to sort the employee table in the descending order of
salaries
24 Write a SQL query to list all the job designation in the employee table
without repetition
25 Write a SQL query to display all the employee details department wise
and in the ascending order of their salaries
26 Write a SQL query to display all the clerks in deptid D2
27 Write a SQL query to display all the employees joined in the year 2011
28 Write a SQL query to display all the employees who joined in the month
of February
31 Write SQL query to display the students who are not from Telangana or
Andhra Pradesh
32 Create a view to display the columns Sid, name for students belongings to
Telangana
33 Write a SQL query to create an index on column sname
34 Write SQL query to display all female students enrolled under comp
course and who belong to OBC
35 Write SQL query to display the student ids, names and their present age
36 Write SQL query to display the students in the ascending order of their
names for each course
37 Write SQL query to delete all the students records who have enrolled for
comp course and who are born after 2002
38 Write SQL query to add two new columns contact no and email to the
existing fields
39 Write SQL query to display all the student names prefixed with Mr. /Ms
based on gender column
40 Write SQL query to display all the student names where the length of the
name is 5 characters
I. CREATE A LIBRARY TABLE AND DISPLAY OUTPUT FOR THE
FOLLOWING QUERIES
41 Write SQL query to display the list of authors from Himalaya publications
42 Write SQL query to display the total cost of books purchased publisher
wise
43 Write SQL query to count the total number of books under Kalyani
publications
44 Write SQL query to rename the column publisher as publications
45 Writ SQL query to display the books in the ascending order of date
purchased
46 Write SQL query to create an index on the fields book name and author
47 Write SQL query to display the books whose price is between 500 and
700
48 Write SQL query to display the price of all the books by 200 for publishers
other than Himalaya or Kalyani
49 Write SQL query to display the book details where author name contains
the name Sharma
50 Create a view to display the fields bookid and book name where the
publisher is Himalaya

You might also like