This action might not be possible to undo. Are you sure you want to continue?
1. 2. Find out the selling cost AVG for packages developed in Pascal.
select avg(scost) from software where developin='pascal'
Display Names, Ages of all Programmers.
select pname,datediff(year,dob,getdate())as Age from programmer
3. 4. 5. Display the Names of those who have done the DAP Course.
select *from studies where course='dap'
Display the Names and Date of Births of all Programmers Born in January.
select pname,dob from programmer where datepart(mm,dob)=1
What is the Highest Number of copies sold by a Package.
select max(sold) from software 6. 7.
8. 9. Display lowest course Fee..
select min(fee) from studies
How many programmers done the PGDCA Course?
select count(*) from studies where course='pgdca'
How much revenue has been earned thru sales of Packages Developed in C.
select sum(SCOST*sold) from software where developin='c'
Display the Details of the Software Developed by Ramesh.
select * from software where pname='ramesh'
10. How many Programmers Studied at Sabhari.
select count(*) from studies where soundex(institute) = soundex('shabhari')
11. Display details of Packages whose sales crossed the 2000 Mark.
select *from software where scost*sold>2000
12. Display the Details of Packages for which Development Cost have been recovered.
select * from software where scost*sold>=dcost 13. What is the cost of the costliest software developed in Basic. select max(DCOST) from software where developin = 'basic'
14. How many Packages Developed in DBASE.
select count(*) from software where developin = 'dbase'
15. How many programmers studied in Pragathi.
select count(*) from studies where INSTITUTE = 'pragathi' 16. How many Programmers Paid 5000 to 10000 for their course? select count(*) from studies where fee between 5000 and 10000
getdate()) 25. select min(datediff(year.'cobol') 20.17. select min(datediff(year. select pname.datediff(year.'c') or prof2 not in('pascal'.'cobol') or prof2 in('pascal'. What are the Languages studied by Male Programmers. select pname from programmer where datepart(month. COBOL or PASCAL. Display the details of those who don’t know Clipper. How many Female Programmers Are There.dob) = datepart(month.dob. How many people draw salary 2000 to 4000. What is AVG Course Fee select avg(fee) from studies 18. select * from programmer where prof1 = 'c' or prof2 = 'c' 19.getdate()) Experience from programmer order by pname desc 24. select avg(salary) from programmer 28. select prof1 from programmer where gender = 'm' union select prof2 from programmer where gender = 'm' 27.'c') 21. Display the details of the Programmers Knowing C. select count(*) 'Female Programmers' from programmer where gender='f' 26. Who are the Programmers who celebrate their Birthday’s During the Current Month. How many Programmers Don’t know PASCAL and C select count(pname) from programmer where prof1 not in('pascal'. How many Programmers know either COBOL or PASCAL.getdate())) from programmer where gender='f' 23. What is the AVG age of Female Programmers.doj. select count(pname) from programmer where prof1 in('pascal'. 2 . What is the AVG Salary. select count(*) from programmer where salary between 2000 and 4000 29.getdate())) from programmer where gender='m' 22. How old is the Oldest Male Programmer. Calculate the Experience in Years for each Programmer and Display with their names in Descending order.dob.
Display each institute Name with Number of Students.sum(scost*sold)/sum(sold) 'Sales per copy' from software where sold>=1 group by DEVELOPIN 35. select pname.sum(scost*sold)'Sales cost' from software group by DEVELOPIN 34.count(course) No_of_courses. select DEVELOPIN.gender from programmer order by gender desc 39.count(pname) No_of_students from studies group by institute 38. Display the Number of Packages sold by Each Programmer. Display the Number of Packages in Each Language Except C and C++. AVG Selling Cost and AVG Price Per Copy.avg(scost) scost. Gender also. Display each institute name with number of Courses.'cobol') and prof2 not in ('clipper'.'pascal'.avg(dcost) dcost. select INSTITUTE. select DEVELOPIN. Display each language name with AVG Development Cost. costliest and cheapest Packages Developed by him or her.'cpp') group by DEVELOPIN 3 . select institute. Display Names of Male and Female Programmers.'pascal'.min(dcost) mini from software group by pname 36. Display the sales values of the Packages Developed by the each Programmer.sum(scost*sold)'Sales Value' from software group by pname 32. 40. select pname.max(dcost) maxi. Average Cost Per Course. select pname.'cobol') 30. select DEVELOPIN. select pname. Display the Cost of Package Developed By each Programmer. Display the sales cost of the packages Developed by each Programmer Language wise. avg(fee) avg_fee from studies group by INSTITUTE 37. select pname.count(*) No_of_packages from software where DEVELOPIN not in ('c'. Display each programmer’s name.select * from programmer where prof1 not in ('clipper'.sum(sold) from software group by pname 33.sum(dcost) from software group by pname 31. Display the Name of Programmers and Their Packages.
Who is the Above Programmer Referred in 50. avg(sal)as avg_sal from emp where sal>2000 45. select pname from programmer where salary=(select max(salary) from programmer where prof1='cobol' or prof2='cobol') and gender = 'f' 47. DCOST for Each Package. Which Language is known by only one Programmer. DCOST and amount to Be Recovered for each Programmer for Those Whose Cost has not yet been Recovered. Display the names of the highest paid programmers for each Language.doj<s.count(*) No_of_packages from software where dcost<1000 group by DEVELOPIN 42. Who is the Highest Paid Female COBOL Programmer. select max(sal) maximum_sal.min(sal)as minimum_sal. select pname from programmer where gender = 'm' and (prof1 = 'pascal' or prof2 = 'pascal') and doj=(select min(doj) from programmer where gender = 'm' and (prof1 = 'pascal' or prof2 = 'pascal')) 50. Who is the Highest Paid C Programmers. Lowest and Average Salaries for those earning more than 2000. 48. Display the total SCOST. Display the Number of Packages in Each Language for which Development Cost is less than 1000. select DEVELOPIN.sum(dcost) sum_of_dev_cost. select pname. select title. select pname from programmer where salary=(select max(salary) from programmer where prof1='c' or prof2='c') 46. select pname from programmer p where 0= (select count(doj) from programmer s where p. 52. Display AVG Difference between SCOST. Display Highest.sum(scost) sum_of_sold. 4 .41. 51.sum(scost*sold) Recoverde_revenue from software where (scost*sold)<dcost group by pname 44.doj) 49. Who is the most experienced male programmer knowing PASCAL. Who is the least experienced Programmer. Who is the Youngest Programmer knowing DBASE. abs(avg(dcost)-avg(scost)) from software group by title 43.
Display the language used by each programmer to develop the Highest Selling and Lowest-selling package.doj)=1992) and datepart(day. Which package has the Highest Development cost. How many copies of package that has the least difference between development and selling cost where sold. which have recovered more than double the Development cost. Which language has used to develop the package. Display the programmer Name and the cheapest packages developed by them in each language. Which Female Programmer earning more than 3000 does not know C. 57. which have sold less than the AVG number of copies. 61. 67. Display the name of the Institute and Course. 63.doj)) from programmer where gender = 'f' and datepart(year. What is the Costliest course. 54. 62. 70. 66. which has below AVG course fee. 74. 68. Who is the oldest Female Programmer who joined in 1992. 69.doj)) from programmer where gender = 'f' and datepart(year. 73. C++. Display the names of the packages. Who is the Author of the Costliest Package. 64. 72. 56. Which language was used to develop the most number of Packages. ORACLE or DBASE. Which programmer has developed the highest number of Packages. 71. Which course has been done by the most of the Students. 55. Who is the youngest male Programmer born in 1965. Which Package has the lowest selling cost.doj)=1992) 5 . Which Institute has most number of Students.doj)=1992 and datepart(month. select pname from programmer where gender = 'f' and datepart(year. 59.doj)=(select min(datepart(day. 58.53. which has the highest sales amount.doj)=(select min(datepart(month. Display the names of the courses whose fees are within 1000 (+ or -) of the Average Fee. Which course has below AVG number of Students. 75. Which Institute conducts costliest course. Which is the costliest package developed in PASCAL. 60. 65. Who are the authors of the Packages. Who Developed the Package that has sold the least number of copies.
select title from software where developin='pascal' and pname in (select pname from programmer where gender = 'f') 85. 82. Display the details of the Programmers who joined before 1990. 6 .doj)) = (select max((select count(datename(month. In which month did most number of programmers join. programmer p where institute='bdps' and gender = 'f' and s. Display the details of the Software Developed in C By female programmers of BDPS. Which language has been stated as the prof by most of the Programmers.pname) 87. Display the details of the Software Developed by the Male Programmers Earning More than 3000/-.76.doj))from programmer group by datename(month. 79. Who are the Female Programmers earning more than the Highest Paid. No. In which language are most of the programmers proficient. select title from software where pname in (select pname from programmer where salary>3000 and gender='m') 84. 81. of Copies Sold and sales value of each programmer institute wise.doj) having count(datepart(month. select * from programmer where salary in (select salary from programmer group by salary having count(salary)>1) order by salary 83.doj) from programmer group by datename(month. Display the details of the packages developed in Pascal by the Female Programmers. select datename(month. Display the number of packages. select title from software where developin='c' and pname in (select s. In which year was the most number of Programmers born. 77.pname from studies s. Display the details of those who are drawing the same salary. select *from programmer where gender = 'm' and salary<(select avg(salary) from programmer where gender='f') 80.doj)))) 78. Who are the male programmers earning below the AVG salary of Female Programmers.doj)<1990 86. select * from programmer where datepart(year.pname=p.
select sf. 89.studies st where sf. Display the names of the programmers who have not developed any packages. Display the details of the software developed by the male students of sabhari.institute. Who are the programmers who have the same Prof2.sum(sold*scost) svalue from software sf.doj) from programmer where datepart(dw. select pname.sum(sold) sold.doj) having count(datepart(dw.title from software where pname in (select pname from programmer where (gender='f' and datepart(year.prof2 from programmer where prof2 in(select prof2 from programmer group by prof2 having count(prof2)! =1)order by prof2 7 .datename(dw.institute order by institute 88. select pname.pname=p. Display the details of the software that has developed in the language which is neither the first nor the second proficiency of the programmers.pname select pname from programmer where pname not in (select pname from software) 93. select pname.doj) from programmer group by datepart(dw. Display the details of the software developed in DBASE by Male Programmers. Who are the programmers who joined on the same day.doj)in(select datepart(dw.pname=st.dob)<1965)) order by pname 90. What is the total cost of the Software developed by the programmers of Apple.dob)>1975) or (gender='m' and datepart(year. select pname. s.pname group by sf. who belong to the institute in which most number of Programmers studied.title from software where pname in(select s.pname. Display the details of the software Developed by the male programmers Born before 1965 and female programmers born after 1975.pname.sum(dcost)from software where pname in(select pname from studies where institute = 'apple')group by pname 94.programmer p where and institute = 'sabhari' and gender='m') 92. select title.developin from software where developin not in(select prof1 from programmer union select prof2 from programmer) 91.doj))! =1)order by datename(dw.count(title) packages.doj) desc 95. select pname.pname from studies s.
How much does the person who developed the highest selling package earn and what course did HE/SHE undergo.pname. How many months will it take for each programmer to recover the cost of the Course Underwent select p.pname=(select pname from software where scost=(select max(scost) from software)) 100.pname. where did HE/SHE studied.96. Which is the costliest package by a person with under 3 year’s experience. select avg(salary) avg_salary from programmer where pname in (select pname from software where scost*sold > 50000) 103.pname. select pname. who studied in institute that charge the lowest course fee. select p. select prof1 from programmer where prof1 not in (select developin from software) union select prof2 from programmer where prof2 not in (select developin from software) 99. Which language listed in prof1.pname=s.pname.dcost from software where dcost=(select max(dcost) dcost from software where pname in (select pname from programmer where datediff(year. select pname.programmer p where s.pname 101. studies s where p.fee/salary months from studies s. select i.count(title).institute from software s.doj. course from programmer p.studies i where s.getdate())<18)) 102. select s. How many packages were developed by the person who developed the cheapest package.pname.count(*) packages from software where pname in (select pname from studies where institute in (select institute from studies where fee in (select min(fee)from studies))) group by pname 104.software s where i. In which institute does the person who developed the costliest package studied.pname=i. institute wise. How many packages were developed by students.title.pname and dcost=(select min(dcost) from software) group by s.000/-. What is the AVG salary for those Whose software sales is more than 50.pname group by institute 97.institute from studies i. Display the total sales value of the software.studies i where i.institute 8 .pname=s.pname=p.pname and p.sum(scost*sold) total_sales from software s. select institute.salary.prof2 has not been used to develop any package.pname and dcost=(select max(dcost) from software) 98.pname=s.
institute from software s. How many packages are developed by the most experienced programmer form BDPS.pname. 107.pname 108.pname. select s.programmer p where s.pname 106.105.pname group by p. How many packages were developed by the female programmers earning more then the highest paid male programmer.pname and salary>(select max(salary) from programmer where gender = 'm') group by s.pname TABLE NAME: STUDIES PNAME ANAND ALTAF JULIANA KAMALA MARY NELSON PATRICK QADIR RAMESH REBECCA REMITHA REVATHI VIJAYA INSTITUTE SABHARI COIT BDPS PRAGATHI SABHARI PRAGATHI PRAGATHI APPLE SABHARI BRILLIANT BDPS SABHARI BDPS COURSE PGDCA DCA MCA DCA PGDCA DAP DCAP HDCA PGDCA DCAP DCS DAP DCA COURSE FEE 4500 7200 22000 5000 4500 6200 5200 14000 4500 11000 6000 5000 4800 TABLE NAME: PROGRAMMER PNAME ANAND ALTAF JULIANA KAMALA MARY NELSON PATTRICK QADIR DOB 12-APR-66 02-JUL-64 31-JAN-60 30-OCT-68 24-JUN-70 11-SEP-65 10-NOV-65 31-AUG-65 DOJ 21-APR-92 13-NOV-90 21-APR-90 02-JAN-92 01-FEB-91 11-OCT-89 21-APR-90 21-APR-91 GENDER M M F F F M M M PROF1 PASCAL CLIPPER COBOL C CPP COBOL PASCAL ASSEMBLY PROF2 BASIC COBOL DBASE DBASE ORACLE DBASE CLIPPER C SALARY 3200 2800 3000 2900 4500 2500 2800 3000 9 .pname. select p.software s where p.count(title) from programmer p.pname=i. select s.count(title) from software s. Of Packages each has developed. 109.studies i where s.pname=s. List the programmers (form the software table) and the institutes they studied.pname=p. List each PROF with the number of Programmers having that PROF and the number of the packages in that PROF. List the programmer names (from the programmer table) and No.
00 4500.00 1100.00 900.00 18000. FINANCIAL ACCT.95 7500.00 300.00 750. HOSPITAL MGMT.00 3000. DEAD LEE PC UTILITIES TSR HELP PKG.RAMESH REBECCA REMITHA REVATHI VIJAYA 03-MAY-67 01-JAN-67 19-APR-70 02-DEC-69 14-DEC-65 28-FEB-91 01-DEC-90 20-APR-93 02-JAN-92 02-MAY-92 M F F F F PASCAL BASIC C PASCAL FOXPRO DBASE COBOL ASSEMBLY BASIC C 3200 2500 3600 3700 3500 TABLE NAME: SOFTWARE PNAME MARY ANAND ANAND JULIANA KAMALA MARY MARY PATTRICK QADIR QADIR RAMESH RAMESH REMITHA REMITHA REVATHI VIJAYA TITLE README PARACHUTES VIDEO TITLING INVENTORY PAYROLL PKG. CODE GENERATOR README BOMBS AWAY VACCINES HOTEL MGMT.00 599.00 2500.00 13000.00 1900.00 9000.95 725. TSR EDITOR DEVELOPIN CPP BASIC PASCAL COBOL DBASE ORACLE C CPP ASSEMBLY C DBASE PASCAL C ASSEMBLY PASCAL C SCOST 300.00 399.00 DCOST 1200 6000 16000 3500 20000 85000 20000 1200 3000 3100 35000 4500 5000 6000 75000 700 SOLD 84 43 9 0 7 4 23 84 11 21 4 73 51 7 2 6 10 .