B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. SRI SNEHA DEGREE COLLEGE B.Com-Computers II Semester (CBCS) Ravi. M MCA, M.Tech(CSE), [ Ph.D ] SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 0 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. Microsoft Access 2013 Microsoft Access 2013 is a database creation and management program. What is a database? A database is a collection of data that is stored in a computer system. Databases allow their users to enter, access, and analyze their data quickly and easily. They're such a useful tool to generate accurate and timely information in a faster way. It can be useful to serve the information needs of different levels of management in an organization and assists them in making better decisions. Databases in MS- Access are composed of four objects: tables, queries, forms, and reports. Together, these objects allow you to enter, store, analyze, and compile your data however you want. Tables In Access, all data is stored in tables, which puts tables at the heart of any database. In Access, rows and columns are referred to as records and fields. A field is more than just a column. It’s a way of organizing information by the type of data it is. Every piece of information within a field is of the same type. Tables are good for storing closely related information. Example: Forms, queries, and reports Although tables store all of your data, the other three objects—forms, queries, and reports—offer you ways to work with it. Each of these objects interacts with the records stored in your database's tables. Forms Forms are used for entering, modifying, and viewing records. Forms are an easy way to guide people toward entering data correctly. When you enter information into a form in Access, the data goes exactly where the database designer wants it to go: in one or more related tables. Forms make entering data easier. Working with extensive tables can be confusing, and when you have connected tables you might need to work with more than one at a time to enter a set of data. However, with forms it's possible to enter data into multiple tables at once, all in one place. Database designers can even set restrictions on individual form components to ensure all of the needed data is entered in the correct format. Forms help keep data consistent and organized, which is essential for an accurate and powerful database. SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 1 B.Com( Computers) – II Semester [CBCS] Queries 2016-17 (BC:207) Management Information System. Queries are a way of searching for and compiling data from one or more tables. Running a query is like asking a detailed question of your database. When you build a query in Access, you are defining specific search conditions to find exactly the data you want. Queries are far more powerful than the simple searches you might carry out within a table. While a search would be able to help you find the name of one customer at your business, you could run a query to find the name and phone number of every customer who's made a purchase within the past week. A well-designed query can give information you might not be able to find just by looking through the data in your tables. Reports Reports offer you the ability to present your data in print. Reports are useful because they allow you to present components of your database in an easy-to-read format. You can even customize a report's appearance to make it visually appealing. Access offers you the ability to create a report from any table or query. Forms allow you to both add data to tables and view data that already exists. Reports present data from tables and also from queries, which then search for and analyze data within these same tables. Tables, Queries, Forms, and Reports, together these objects allow you to enter, store, analyze, and compile your data however you want. *** SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 2 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. Problem No.1 ( Q.B: 2) 1. Create a Personal Information table in MS-Access with the following fields: a. First Name b. Middle Name c. Last Name d. Nationality e. Gender f. Temporary Address g. Permanent Address. Generate a Form and Report. Solution: Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “Personal Information DB”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “PERSONAL INFORMATION TABLE” and click on OK. 8. Enter the field names and Data types and Description as applicable and Save the Table. 9. Select OPEN by right Clicking on your TABLE (Personal Information Table) from All Access Objects Pane. 10. Enter the Data in to the fields and Save it. Then the table may look like the following: Generating a FORM: 11. Select CREATE menu and Click on FORM It will create a form based on your table data with default layout. 12. Click on SAVE and name it as Personal Information Form. Then the Form may look like the following: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 3 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. Generating a REPORT: 13. Select CREATE menu and Click on REPORT It will create a report based on your table data with default layout. 14. Click on SAVE and name it as Personal Information Report. Then the Report may look like the following: ***** Problem No.2: ( Q.B: 5) Create a database ‘Student’. Also create table ‘studtable’ and execute the following queries SRollno Sname English SL FA-I BE BOM IT 101 Rajendra 75 85 90 85 86 90 102 Arvind 88 75 95 80 82 85 103 Krishna 89 77 82 78 82 86 104 Harish 75 72 70 65 60 77 105 Rajesh 86 85 81 80 89 90 a) Sort the data by Sname. b) Calculate Total Marks of Individual Students. c) Calculate Percentage Marks of Individual Student Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “Student”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “StudTable” and click on OK. 8. Enter the field names and Data types and Description as applicable and Save the Table. 9. Select OPEN by right Clicking on your TABLE (StudTable) from All Access Objects Pane. 10. Enter the Data in to the fields and Save it. Then the table may looks like the following: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 4 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. Sort the data by Sname: 11. Select the field SNAME, Click on the Arrow and Select the option SORT A to Z . Then the data will be sorted as shown below: 12. Select Design View by right Clicking on the object StudTable from All Access Objects Pane. 13. Add a field TOTAL and Select the data type as CALCULATED and enter the expression as [English]+[SL]+[FA]+[BE]+[BOM]+[IT] Calculate Percentage Marks of Individual Students: 14. Select Design View by right Clicking on the object StudTable from All Access Objects Pane. 15. Add a field PERCENTAGE and Select the data type as CALCULATED and enter the expression as [Total]/6 16. Save the Table and OPEN it Then the table may looks like the following: ***** SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 5 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. Problem.No:3 ( Q.B: 6) Create a database ‘Student’. Also create table ‘stdtable’ and execute the following queries SRollno Sname English SL FA-I BE BOM IT 101 Rajendra 75 85 90 85 86 90 102 Arvind 88 75 95 80 82 85 103 Krishna 50 52 58 50 53 54 104 Harish 52 55 51 56 57 59 105 Rajesh 86 85 81 80 89 90 a) Display all Students who got >=80 Marks in Any Subject. b) Display all Students who got >=80% Marks in Total. c) Display all Students who got <=60% Marks in Total. Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “Student1”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “StdTable” and click on OK. 8. Enter the field names and Data types and Description as applicable and Save the Table. 9. Select OPEN by right Clicking on your TABLE (StdTable) from All Access Objects Pane. 10. Enter the Data in to the fields and Save it. 11. Find the Total Marks by using the CALCULATED type. 12. Save the Table. a) Query to display all Students who got >=80 Marks in Any Subject: 13. Select CREATE menu and Click on QUERY DESIGN from the Queries Tab. 14. Select the table StdTable and Check all the columns at Show Property. 15. Apply the criteria as shown below: 16. Save the Query and Click on RUN command. Then, it will run the query and display the result as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 6 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. B) Query to display all Students who got >=80% Marks in Total: 17. Select CREATE menu and Click on QUERY DESIGN from the Queries Tab. 18. Select the table StdTable and Check the columns SRollno, Sname, Total at Show Property. 19. Apply the criteria as shown below: 20. Save the Query and Click on RUN command. Then, it will run the query and display the result as shown below: b) 21. 22. 23. Query to Display all Students who got <=60% Marks in Total: Select CREATE menu and Click on QUERY DESIGN from the Queries Tab. Select the table StdTable and Check the columns SRollno, Sname, Total at Show Property. Apply the criteria as shown below: 24. Save the Query and Click on RUN command. Then, it will run the query and display the result as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 7 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. ***** Problem No:4 ( Q.B: 7) Create a database ‘Student2’. Also create table ‘stdmarks’ and execute the following queries SRollno Sname English SL FA BE BOM FIT 101 Rajendra 22 20 23 20 23 20 102 Arvind 20 21 20 23 20 20 103 Krishna 50 52 58 50 53 54 104 Harish 52 55 51 56 57 59 105 Rajesh 86 85 81 80 89 90 a) Display All the students who got <25 in individual subject. b) Display all the students who are Failed in individual Subject. c) Increase marks by adding 5 marks whose marks are <25. Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “Student2”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “StdMarks” and click on OK. 8. Enter the field names and Data types and Description as applicable and Save the Table. 9. Select OPEN by right Clicking on your TABLE (StdMarks) from All Access Objects Pane. 10. Enter the Data in to the fields and Save it. a) Query to display All the students who got <25 in individual subject. 11. Select CREATE menu and Click on QUERY DESIGN from the Queries Tab. 12. Select the table StdMarks and Check all the columns at Show Property. 13. Apply the criteria as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 8 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. 14. Save the Query and Click on RUN command. Then, it will run the query and display the result as shown below: b) Query to display all the students who are Failed in individual Subject. 15. Select CREATE menu and Click on QUERY DESIGN from the Queries Tab. 16. Select the table StdMarks and Check all the columns at Show Property. 17. Apply the criteria as shown below: 18. Save the Query and Click on RUN command. Then, it will run the query and display the result as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 9 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) c) Query to Increase marks by adding 5 marks whose marks are <25. Management Information System. 19. Select CREATE menu and Click on QUERY DESIGN from the Queries Tab. 20. Select the table StdMarks and Check all the columns at Show Property. 21. Apply the criteria as shown below: 22. Save the Query and Click on RUN command. Then, run the query, it will Warn you before updating the 2 rows and then the Updated StuMarks table will be as shown below: ***** Problem No:5. ( Q.B: 8) 4. Create a database ‘Student3’. Also create table ‘stdmarks1’ and execute the following queries SRollno Sname English SL FA BE BOM FIT 101 Rajendra 90 95 92 90 88 90 102 Arvind 48 52 48 50 53 54 103 Krishna 85 88 89 85 95 90 104 Harish 12 10 15 12 10 15 105 Rajesh 60 66 75 77 65 79 a) Update table by adding Grade as per the following:i. Total %age >=90% Grade “O” ii. Total %age >=75% Grade “A” iii. Total %age >=60% Grade “B” iv. Total %age >=50% Grade “C” v. Total %age >=36% Grade “D” vi. Total %age <36% Grade “F” SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 10 B.Com( Computers) – II Semester [CBCS] Creating a database/Table: 2016-17 (BC:207) Management Information System. 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “Student3”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “StdMarks1” and click on OK. 8. Enter the field names and Data types and Description as applicable and Save the Table. 9. Select OPEN by right Clicking on your TABLE (StdMarks1) from All Access Objects Pane. 10. Enter the Data in to the fields and Save it. 11. Find the Total Marks by using the CALCULATED type. 12. Save the Table. 13. Select Design View by right Clicking on the object StdMarks1 from All Access Objects Pane. 14. Add a field “GRADE” and select the data type as “Short Text” 15. Save the Table. A) 16. 17. 18. 19. Updating table by adding Grade as per the given criteria: Select CREATE menu and Click on QUERY DESIGN from the Queries Tab. Select the table “StdMarks1” and Check Select the field GRADE at Show Property. Click on UPDATE command from the Query Type tab. Apply the condition IIF at Update To constraint as shown below: 20. Save the Query and Click on RUN command. Then, run the query, it will Warn you before updating the 5 rows and then the Updated StuMarks1 table will be as shown below: ***** SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 11 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. Problem No.6: ( Q.B: 9 & 10) 5. Create ‘Employee’ database and table ‘Emp’ Empno Ename Designation Deptno DOJ Basic Salary 101 Ajay Manager 10 12/12/2001 25000 102 Arvind Dy. Manager 40 20/02/2002 20000 103 Rahul Programmer 20 22/03/2001 18000 104 Hari Mktg. Officer 40 01/04/2001 15000 105 Sahil Accountant 20-09-2000 a) b) c) d) e) f) g) h) a. b. 10 12000 Calculate DA as 40% of Basic Salary. Calculate Hra as 15% of Basic Salary. Calculate PF as 12.67% of Basic Salary Calculate Gross Pay = Basic Salary + DA + HRA Calculate Net Pay = Gross Pay – PF. List all the Employees Who are working in Dept no.10 List all the Employees who get less than 20000 Salary. Update Salary by adding the increments as per the following:10% Increment in Basic Salary who get < 20000 5% Increment in Basic Salary who get >20000. Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “EMPLOYEE”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “EMP” and click on OK. 8. Enter the field names and Data types and Description as gievn and Save the Table. A) 9. Find the DA by using the CALCULATED type and Enter the Expression as BasicSalary * 40 /100 B) 10. Find the HRA by using the CALCULATED type and Enter the Expression as BasicSalary * 15 /100 C) 11. Find the PF by using the CALCULATED type and Enter the Expression as BasicSalary * 12.67 /100 D) 12. Find the Grosspay by using the CALCULATED type and Enter the Expression as BasicSalary +HRA+DA E) 13. Find the NetPay by using the CALCULATED type and Enter the Expression as GrossPay – PF 14. Select OPEN by right Clicking on your TABLE (EMP) from All Access Objects Pane. SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 12 B.Com( Computers) – II Semester [CBCS] 2016-17 15. Enter the Data in the required fields and Save it. (BC:207) Management Information System. Then the EMP table may look like as shown below: F) To List all the Employees Who are working in Dept no.10: 16. Select CREATE menu and Click on QUERY DESIGN from the Queries Tab. 17. Select the table “EMP” and Check Select only the require fields at Show Property. 18. Apply the condition as shown below: 21. Save the Query and Click on RUN command. Then, it displays the result as shown below: G) To List all the Employees who get less than 20000 Salary: 1. Select CREATE menu and Click on QUERY DESIGN from the Queries Tab. 2. Select the table “EMP” and Check Select only the require fields at Show Property. 3. Apply the condition as shown below: 22. Save the Query and Click on RUN command. SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 13 B.Com( Computers) – II Semester [CBCS] 2016-17 Then, it displays the result as shown below: (BC:207) Management Information System. H) To update 10% Increment in Basic Salary who get < 20000: 23. Select CREATE menu and Click on QUERY DESIGN from the Queries Tab. 24. Select the table “EMP” and Check Select only the require fields at Show Property. 25. Apply the condition as shown below: 26. Save the Query and Click on RUN command. 27. Then, run the query, it will Warn you before updating the 3 rows and then the Updated EMP table will be as shown below: I) To update 5% Increment in Basic Salary who get > 20000: 28. Select CREATE menu and Click on QUERY DESIGN from the Queries Tab. 29. Select the table “EMP” and Check Select only the require fields at Show Property. 30. Apply the condition as shown below: 31. Save the Query and Click on RUN command. 32. Then, run the query, it will Warn you before updating the 1 row and then the Updated EMP table will be as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 14 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. ***** Problem No. 7 ( Q.B: 14 & 15) Create ‘Course’ database and ‘Coursedtl’ table having following records:SRollno Sname Course Section Medium College Total Fees 101 Rajendra B.Com General English ABC 5500 102 Arvind B.Com General English PQR 15000 103 Krishna B.Com General Telugu ABC 5500 104 Harish B.Com General Telugu PQR 7500 105 Rajesh B.Com Computers English ABC 15000 106 Harish B.Com Computers English PQR 25000 a) b) c) d) Prepare the report to display lowest course fees with college name. Prepare the Report to display all students who are pursuing B.Com(Computers). Display the Course and College having Lowest Course Fees. Display all the courses offering by the PQR College. Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “COURSE”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “CourseEdt1” and click on OK. 8. Enter the field names and Data types and Description as given and Save the Table. 9. Select OPEN by right Clicking on your TABLE (CourseEdt1) from All Access Objects Pane. 10. Enter the Data in the required fields and Save it. A) 11. 12. 13. To Prepare Query1 for the report to display lowest course fees with college name: Select CREATE menu and Click on QUERY DESIGN from the Queries Tab. Select the table “CourseEdt1” and Check /Select only the required fields at Show Property. Apply the condition as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 15 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. 14. Click on CREATE and Select Report Wizard. 15. Create the Report based on the above Query1 16. Save and Run the Report. It may look like as shown below: B) To Prepare Query2 for the report to display all students who are pursuing B.Com(Computers): 17. Create a new query and apply the condition as shown below: 18. Click on CREATE and Select Report Wizard. 19. Create the Report based on the above Query2 20. Save and Run the Report. It may look like as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 16 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. e) To display the Course and College having Lowest Course Fees: 21. Create a new query and apply the condition as shown below: 22. Save the Query and Click on RUN command. 23. Then, it displays the results as shown below: f) To Display all the courses offering by the PQR College: 24. Create a new query and apply the condition as shown below: 25. Save the Query and Click on RUN command. 26. Then, it displays the results as shown below: ***** SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 17 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. Problem.No:8 ( Q.B: 16) Create a Library Database of your college having following fields and enter at least 30 records in it:Field Name Description BookCode Primary Key BookTitle Subject Name Publisher Book Publisher Name No.of.Copies Quantity in one Invoice No.ofPages Total Pages in book Edition Book Printing Edition From the College Library database find out the following:a. Total no. of copies of books subject wise. b. A report displays all books group by Publisher. c. A report displays all books group by Book Title. d. A report displays all books group by Book Edition Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “LIBRARY”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “BOOKS” and click on OK. 8. Enter the field names and Data types and Description as shown below: 9. Save the Table. 10. Select OPEN by right Clicking on your TABLE (Books) from All Access Objects Pane. 11. Enter 30 records of Data and Save it. Then the table may looks like the following: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 18 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. A). Query to find Total no. of copies of books subject wise. 12. Create a new query and apply the condition as shown below: 13. Save the Query and Click on RUN command. 14. Then, it displays the results as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 19 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. B). To Generate A report that displays all books group by Publisher: 15. Create a new query and apply the condition as shown below: 16. Save the Query 17. Click on CREATE and Select REPORT. Then, Access will create a Report based on the query, as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 20 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. C). To Generate A report that displays all books group by Book Title: 1. Create a new query and apply the condition as shown below: 2. Save the Query 3. Click on CREATE and Select REPORT. Then, Access will create a Report based on the query, as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 21 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. D). To Generate A report that displays all books group by Book Title: 1. Create a new query and apply the condition as shown below: 2. Save the Query 3. Click on CREATE and Select REPORT. Then, Access will create a Report based on the query, as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 22 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. ***** Problem No: 9( Q.B: 19): Create a ‘Sales’ Database and a table ‘Salesdtl’ having following fields and data:Salesman Salesman Sale SalesNo. Code Name Branch Amount 1011 101 Arvind Jaipur 75000 1012 102 Ashok Jaipur 80000 1013 103 Harish Hyderabad 75000 1014 104 Manish Hyderabad 65000 1015 105 Krish Secunderabad 78000 Generate the queries to find out the followings from the above ‘Sales’ Table: a) Total sale of all the Branches. b) Total sale group by Branches. c) Maximum sale of individual branch. d) Maximum sale in all branches. Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “SALES”) and click on CREATE. SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 23 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “SalesDt1” and click on OK. 8. Enter the field names and Data types and Description as required. 9. Save the Table. 10. Select OPEN by right Clicking on your TABLE (SalesDt1) from All Access Objects Pane. 11. Enter the given Data and Save it. A) To Find Total sale of all the Branches. 12. Create a new query and apply the condition as shown below: 13. Save the Query and Click on RUN command. 14. Then, it displays the results as shown below: B) To find Total sale group by Branches: 15. Create a new query and apply the condition as shown below: 16. Save the Query and Click on RUN command. 17. Then, it displays the results as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 24 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. C) To find Maximum sale of individual Branch: 18. Create a new query and apply the condition as shown below: 19. Save the Query and Click on RUN command. 20. Then, it displays the results as shown below: D) To find Maximum sale in all Branches: 21. Create a new query and apply the condition as shown below: 22. Save the Query and Click on RUN command. 23. Then, it displays the results as shown below: ***** SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 25 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. Problem No:10 ( Q.B: 21) Create an ‘Stock’ database having an ‘Inventory’ Table as per the followings:Product Code Product Name Purchase Quantity Purchase Price 1011 CPU 200 15000 1012 Monitor 100 7500 1013 Printer 75 5500 1014 UPS 200 3500 1015 Speakers 200 250 Generate the following queries from the above ‘Inventory ‘Table:a) Item wise total purchase price. b) Display new purchase price after adding 15% increase in purchase price. c) Display new Purchase quantity after deducting 5% from the quantity Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “EMPLOYEEDB”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “EMPLOYEE” and click on OK. 8. Enter the field names and Data types and Description as required. 9. Save the Table. 10. Select OPEN by right Clicking on your TABLE (EMPLOYEE) from All Access Objects Pane. 11. Enter the given Data and Save it. Then the table may look like the following: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 26 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. A). To Display Item wise total purchase price: 12. Create a new query and apply the condition as shown below: 13. Save the Query and Click on RUN command. 14. Then the result can be as shown below: B). To Display new purchase price after adding 15% increase in purchase price: 15. Create a new query and apply the condition as shown below: 16. Save the Query and Click on RUN command. Then the result can be as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 27 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. C). Display new Purchase quantity after deducting 5% from the quantity 17. Create a new query and apply the condition as shown below: 18. Save the Query and Click on RUN command. 19. Then the result can be as shown below: ***** SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 28 B.Com( Computers) – II Semester [CBCS] 2016-17 Problem No. 11: ( Q.B: 23) Create a ‘Stock’ database having ‘Inventory’ table:Item Code Name of the Item Opening Stock (BC:207) Management Information System. Purchase Sales 1011 CPU 200 150 300 1012 Monitor 100 100 150 1013 Printer 75 150 125 1014 UPS 200 300 400 1015 Speakers 200 250 350 Generate the following queries from the above table:a) Calculate the closing stock of each item (Closing Stock = Opening Stock + Purchase – Sales) b) Display all the Items which has closing stock < 100 c) If closing stock is less than 100 then set the remark as “Re-Order Level” otherwise “Enough Stock”. Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “STOCK”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. 7. 8. 9. 10. 11. 12. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. Rename the table as “INVENTORY” and click on OK. Enter the field names and Data types and Description as required. Save the Table. Select OPEN by right Clicking on your TABLE (SalesDt1) from All Access Objects Pane. Enter the given Data and Save it. Find the CLOSING STOCK by using the CALCULATED data type and Enter the Expression as [OpeningStock]+[Purchase]-[Sales] 13. Find the REMARKS by using the CALCULATED data type and Enter the Expression as IIf([Closing Stock]<100,"Re-Order Level","Enough Stock") Then the table looks like the following: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 29 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. A) To display all the items which has closing stock < 100 14. Create a new query and apply the condition as shown below: 15. Save the Query and Click on RUN command. 16. Then, it displays the results as shown below: ***** Problem No. 12: ( Q.B: 27) Create a FEE table in access with (Name,Category,Course/Group,Year, Fees). Insert 10 records. Add new column concession. Write a query to calculate concession. calculate concession=fee*20/100; when category is NCC/NSS/GIRL Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “FEEDB”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “FEE” and click on OK. 8. Enter the field names and Data types and Description as required. 9. Save the Table. 10. Select OPEN by right Clicking on your TABLE (FEE) from All Access Objects Pane. 11. Enter the given Data and Save it. Then the table may look like the following: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 30 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. 12. Add a Filed CONCESSION to the FEE table and Save it. A) Query to calculate concession: Create a new query and apply the condition as shown below: 13. Save the Query and Click on RUN command. 14. Then, it warns you to update 5 rows and updates the table. Then the table looks as shown below: ***** Problem No.13: ( Q.B: 28) Create a table (person) in access with name,phno,email-id and address . insert 10 records. Create a query to display email id,phno and address when user gives name. Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 31 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “PERSONDB”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “PERSON” and click on OK. 8. Enter the field names and Data types and Description as required. 9. Save the Table. 10. Select OPEN by right Clicking on your TABLE (FEE) from All Access Objects Pane. 11. Enter 10 Record of Data and Save it. Then the table may look like the following: A) Create a query to display email id,phno and address when user gives name. 12. Create a new query and apply the condition as shown below: 13. Save the Query and Click on RUN command. 14. Then, it prompts you for your Input as shown below: 15. Enter a Name and Click OK. Then it displays the result as shown below: ***** SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 32 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. Problem No.14: ( Q.B: 29) Create a SALES table in access with (ID,productname,quantity,salesrate,commission,tax) Insert 10 records. Add newcolumn affiliate earnings. Write a query to calculate affiliate earnings. calculate earnings=(quantity*salesrate)+commission-tax. Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “SALESDB”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “SALES” and click on OK. 8. Enter the field names and Data types and Description as required. 9. Save the Table. 10. Select OPEN by right Clicking on your TABLE (FEE) from All Access Objects Pane. 11. Enter 10 Record of Data and Save it. Then the table may look like the following: 12. Add a Field AFFILIATE EARNINGS to the SALES table and Save it. B) Query to calculate Affiliate Earnings: 13. Create a new query and apply the condition as shown below: 14. Save the Query and Click on RUN command. SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 33 affiliate B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. 15. Then, it warns you to update the rows and updates the table. Then the table looks as shown below: ***** Problem No:15: ( Q.B: 34) Create a database ‘Library’ and create a table as ‘Books’ and execute the queries given below: Author Lname Author Fname Book title Book type Year of publication Gupta Sharma Management Accounting Accounting 2002 Nain Patel Financial Accounting 2000 Reddy Ram Corporate Accounting Accounting 1990 a) Display Book title, Book type, author name where author = Ram and book type = Accounting. b) Display Author Fname, Book type year of publication where year above 2000. Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “LIBRARYDB”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “BOOKS” and click on OK. 8. Enter the field names and Data types and Description as required. 9. Save the Table. 10. Select OPEN by right Clicking on your TABLE (BOOKS) from All Access Objects Pane. 11. Enter the given Data and Save it. Then the table may look like the following: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 34 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. A). To display Book title, Book type, author name where author = Ram and book type = Accounting. 12. Create a new query and apply the condition as shown below: 13. Save the Query and Click on RUN command. 14. Then, it warns you to update the rows and updates the table. Then the table looks as shown below: B). To display Author Fname, Book type year of publication where year above 2000. 15. Create a new query and apply the condition as shown below: 16. Save the Query and Click on RUN command. Then, it warns you to update the rows and updates the table. Then the table looks as shown below: ***** SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 35 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Problem No.16: ( Q.B: 40) Create table textbook with the following fields. Book title, Author name, Publication name, Quantity, Price. Management Information System. Insert 10 records. Create query to display the books of information technology, Create query to display the books of Himalaya publications. Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “TEXTBOOKDB”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “TEXTBOOK” and click on OK. 8. Enter the field names and Data types and Description as required. 9. Save the Table. 10. Select OPEN by right Clicking on your TABLE (TEXTBOOK) from All Access Objects Pane. 11. Enter the given Data and Save it. Then the table may look like the following: A). To create a query to display the books of information technology, 12. Create a new query and apply the condition as shown below: 13. Save the Query and Click on RUN command. 14. Then, it warns you to update the rows and updates the table. Then the table looks as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 36 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. B). To create query to display the books of Himalaya publications. 15. Create a new query and apply the condition as shown below: 16. Save the Query and Click on RUN command. 17. Then, it warns you to update the rows and updates the table. Then the table looks as shown below: ***** Problem No. 17: ( Q.B: 41) Create a table student with the following fields (Rno, Name, FA marks, BE marks, IT marks, Total and Average). Insert 10 records, Calculate total = fa+be+it. Average = total/ no of subjects. Create a query to display all information of student who secured >75 marks in IT subject. Create a query to display name, total and average who’s average is > 80. Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 37 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “TEXTBOOKDB”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “TEXTBOOK” and click on OK. 8. Enter the field names and Data types and Description as required. 9. Find the TOTAL by using the CALCULATED data type and Enter the Expression as [FA]+[BE]-[IT] 10. Find the AVERAGE by using the CALCULATED data type and Enter the Expression as [TOTAL] / 3 11. Save the Table. 12. Select OPEN by right Clicking on your TABLE (TEXTBOOK) from All Access Objects Pane. 13. Enter the given Data and Save it. Then the table may look like the following: A). To Create a query to display all information of student who secured >75 marks in IT subject. 14. Create a new query and apply the condition as shown below: 15. Save the Query and Click on RUN command. 16. Then the result can be as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 38 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. B). To Create a query to display name, total and average who’s average is > 80. 17. Create a new query and apply the condition as shown below: 18. Save the Query and Click on RUN command. 19. Then the result can be as shown below: ***** Problem No. 18: ( Q.B: 42) Create a table employee with (idno, name, job, age, salary). Insert 10 records. Create a query to display the information of all managers. Create a query to display the names of employs who’s salary is >15000. Creating a database/Table: 1. Click on Start Menu 2. Click on RUN command ( OR Press Win key + R ) It will display a run dialogue box 3. Type “MSACCESS” in the run dialogue box and click on OK. It will display an MS-ACCESS-2013 application window. 4. Select and Click on “Blank Desktop Database”. It will prompt you to enter the name of the database. 5. Type a name for the database (For example: “EMPLOYEEDB”) and click on CREATE. Then, It will create your database with a blank Table, TABLE1. 6. Select Design View by right Clicking on the object TABLE1 from All Access Objects Pane. 7. Rename the table as “EMPLOYEE” and click on OK. 8. Enter the field names and Data types and Description as required. 9. Save the Table. 10. Select OPEN by right Clicking on your TABLE (EMPLOYEE) from All Access Objects Pane. 11. Enter the given Data and Save it. Then the table may look like the following: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 39 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. A). To Create a query to display the information of all managers. 12. Create a new query and apply the condition as shown below: 13. Save the Query and Click on RUN command. 14. Then the result can be as shown below: B). To Create a query to display the names of employs who’s salary is >15000. 15. Create a new query and apply the condition as shown below: 16. Save the Query and Click on RUN command. 16. Then the result can be as shown below: SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 40 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. ***** SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 41 B.Com( Computers) – II Semester [CBCS] 2016-17 (BC:207) Management Information System. SRI SNEHA DEGREE COLLEGE :: BHONGIR (4066) 42