Vivek
Vivek
AND MANAGEMENT
MDU , ROHTAK
PRACTICAL FILE
NAME : VIVEK
COURSE /SEMESTER :
BCA III
REGISTRATION-NO :-2317521255
SUBJECT : SQL(BCA-203)
SUBMITTED TO : DR.RAMESH KUMAR
SHARMA
Query1:- Display name and
commission for all the salesmen.
OUTPUT:-
OUTPUT:-
Query2:- Retrieve salesman id
of all salesmen from orders table
without any repeats.
OUTPUT:-
OUTPUT:-
Query3:- Display names and city
of salesman, who belongs to the
city of Paris.
OUTPUT:-
OUTPUT:-
Query4:- Display all the
information for those customers
with a grade of 200.
OUTPUT:-
OUTPUT:-
Output:
Query 9: Show all the winners of
Nobel prize in the year 1970
except the subject physiology
and economics.
Output:
Query 10: Find all the details of
the Nobel winners for the subject
not started with the letter 'P' and
arranged the list as the most
recent comes first, then by name
in order.
Output:
Query 11: Find the name and
price of the cheapest item.
Output:
Output:
Query13:- Find those salesmen
with all information who gets the
commission within a range of
0.12 and 0.14.
Output:-
Output:-
Output:-
Output:-
Query15:- Find those salesmen
with all information whose name
containing the 1st character is 'N'
and the 4th character is 'l' and
rests may be any character.
Output:-
Output:-
Query16:- Find that customer
with all information who does not
get any grade except
NULL.
Output:-
Output:-
Query17:- Find the total
purchase amount of all orders.
Output:-
Output:-
Query18:- Find the number of
salesman currently listing for all
of their customers.
Output:-
Output:-
Query19:- Find the highest
grade for each of the cities of the
customers.
Output:-
Output:-
Query20:- Find the highest
purchase amount ordered by the
each customer with their ID and
highest purchase amount.
Output:-
Output:-
Query21:- Find the highest
purchase amount ordered by the
each customer on a particular
date with their ID, order date and
highest purchase amount.
Output:-
Output:-
Query22:- Find the highest
purchase amount on a date
'2012-08-17' for each salesman
with their ID.
Output:-
Output:-
Query23:- Find the highest
purchase amount with their
customer ID and order date, for
only those customers who have
the highest purchase amount in a
day is more than 2000.
Output:-
Output:-
Query24:- Write a SQL
statement that counts all orders
for a date August 17th, 2012.
Output:-
Output:-