Concept explainers
Explanation of Solution
Name of spreadsheet: COMPANY
Column names:
Name | IndustryCode | Gross Sales | OfficerName | OfficerTitle |
The above spreadsheet contains Name, IndustryCode, Gross Sales, OfficerName, and OfficerTitle.
Divide the columns into tables with single theme:
Industry details:
Industry_id | Name | IndustryCode |
1 | SUN | 352-765 |
2 | Anime | 654-123 |
Officer details:
Officer_id | OfficerName | OfficerTitle |
1 | Ram Kumar | ceo |
2 | Rajesh | Project Head |
Sales details:
Industry_id | Officer_id | Gross Sales |
1 | 1 | 23000000 |
2 | 2 | 45000000 |
1 | 2 | 50000000 |
- Number of themes: Three
- Name of the theme: Industry details, officer details, and Sales
Assumptions:
In the above spreadsheet, there are three themes. One of the themes is about industry which is specified through the heading of Name and IndustryCode. The other theme is about officer who is specified through the heading of OfficerName and OfficerTitle. The final theme is about sales which are specified through the heading of Gross Sales.
- Industry – It contains Industry_id, Name and IndustryCode attributes. The Industry_id is the primary key of the Industry table.
- Officer – It contains Officer_id, OfficerName, and OfficerTitle attributes. The Officer_id is the primary key of the Officer table.
- Sales – It contains Industry_id, Officer_id, and Gross Sales attributes.
Name of spreadsheet: COMPANY
Column names:
Name | IndustryCode | Gross Sales | NameOfOwner |
The above spreadsheet contains Name, IndustryCode, Gross Sales and NameOfOwner.
Divide the columns into tables with single theme:
Industry details:
Industry_id | Name | IndustryCode | NameOfOwner |
1 | SUN | 352-765 | XXX |
2 | Anime | 654-123 | YYY |
Sales:
Industry_id | Gross Sales |
1 | 23000000 |
2 | 45000000 |
1 | 50000000 |
- Number of themes: Three
- Name of the theme: Industry details and Sales
Assumptions:
In the above spreadsheet, there are three themes. One theme is about industry which is specified through the heading of Name and IndustryCode. The other theme is about president which is specified through the heading of NameOfPresident. The final theme is about a sale which is specified with the heading of Gross Sales.
- Industry – It contains Industry_id, Name, IndustryCode, and NameOfOwner attributes. The Industry_id is the primary key of the Industry table.
- Sales – It contains Industry_id, and Gross Sales attributes.
Name of spreadsheet: COMPUTER
Column names:
SerialNumber | Make | Model | DiskType | DiskCapacity |
The above spreadsheet contains SerialNumber, Make, Model, DiskType and DiskCapacity...
Want to see the full answer?
Check out a sample textbook solutionChapter 1 Solutions
EBK DATABASE CONCEPTS
- Using the getFirst() function as a template for reference, code the saveProduct() function that will be called when the save button of the depicted screen is clicked. The text from the JTextFields will be used as parameters.The database schema for the SQL tables are also depicted. The number of the product is the primary key and is set to auto-increment. public Product getFirst() { if (openConnection()) { try{ Product temp = null; String query = "SELECT * FROM products order by number asc limit 1"; // our SQL SELECT query. Statement st = conn.createStatement(ResultSet.TYPE_SCROLL_SENSITIVE,ResultSet.CONCUR_READ_ONLY); // create the java statement ResultSet rs = st.executeQuery(query);// execute the query, and get a java resultset while (rs.next()) // iterate through the java resultset { temp = new…arrow_forwardCreate an MVC web application having the index view given below. The given view will be populated from the model book having data members (Id, Title). Write only the code for the model class with the action SubmitImg() to submit the data in the database table book(id, title). Use suitable data annotations attributes to perform empty field validation also. No need to write view code.arrow_forwardWhile the datamodel design process was still underway, an enterprising accountant started putting together data in a spreadsheet already. Tshepo applauded his enthusiasm, but he is worried about the integrity of the data, despite the fact that the accountant says his data is in first normal form already. Here is a sample of the spreadsheet data, in first normal form (underlined columns names indicate the composite primary key): Company Company Department Department Product Product Name ID Name ID ID Name VR1000 Product Product Type ID Type Name 1 Headset 1 1 ACME VR ACME VR ACME VR 1 1 1 0 No Product Date Value 3306/01/23 521 3306/01/24 -250 3306/01/23 105 3306/01/23 999 3306/01/23 50 1 Production Production HR Finance Production 2 0 No Product 2 ACME Movies 3 0 No Product MC9 2 ACME Movies 4 2 2 Cameraarrow_forward
- In a database, Write SQL query to show table structure of table name Guardians.arrow_forwardComputer Science At UFL, each class is a specific offering of a course (subject). Each row in the Courses table contains information on a single course or subject taught a UFL and each row in the Classes table contains information on a single offering of a course during a specific term. Investigate the two tables, and then write a query that returns the CourseTitle, ClassID, Term, SectionID and FacultyID for classes taught by FacultyID 5000009. SOLUTION:arrow_forwardfrom structured query language coursearrow_forward
- Using the Henry Books database, add the new title from Stephen King to the wrote table: Book code = 3578 Author number = 6 Edition = 1 You will insert 2 snips for this question. What construct did you use to add a row to the wrote table. Insert the snip of the construct used: Insert the snip of the wrote table. Be sure the new row is displayed:arrow_forwardQ1: Identify one PK from each table and add the constraints using alter.arrow_forwardCreate an MVC web application having the index view given below. Given view will be populated from the model book having data members (Id, Title). Write only the code for the model class with the action Submitlmg() to submit the data in database table book(id, title). Use suitable data annotations attributes to perform empty field validation also. No need to write view code. Book Form Book Id Book Title Savearrow_forward
- C sharp Table: Student (the headers are the field names in the Students table) StudentID Name Age Gender ProgramID 791 Stephanie Brown 19 Female BCS 236 Shannon Dawn 25 Female BA 618 Geoff Berg 24 Male ARET 256 Andrew Schilling 22 Male BSC 902 Gary Sang 23 Male DAAD Note: There is a StudentDataSet with a Student table, a StudentTableAdapter, a StudentBindingSource, and a StudentDataGridView control on the form.Note: There is an Average query, named Average, that returns the average age of the student from the Student table.Note: There is also Max query, named Highest, that returns the highest age of the student from the Student table.Write the code you would place in the AverageButton click event on your form to call the Average query and the Highest query and display in a DifferenceLabel, the difference between the highest age of a student and the average age.arrow_forwardThere are three tables in this database (see image). Write MYSQL code for: (1) Create a trigger “insert_inventory” on table “Inventory”. The trigger is fired after a row is inserted in table “Inventory”. After a row is inserted in table “inventory”, the “itemid”, the insertion time, and the action is inserted in table “Inventory_history”. The action is set to ‘add an item’. The oldprice is set to null. Test your trigger by inserting a row into Inventory and displaying the contents of Inventory_history. (2) Create a trigger “change_quantity” on table “Transaction”. The trigger is fired after a row is inserted in table “Transaction”. After a row is inserted in table “Transaction”, update the “quantity” in table “Inventory”. For example, if 3 iWatch are sold, then the quantity of iWatch in table “Inventory” is decreased by 3. Test your trigger by inserting a row into Transaction and displaying the contents of the relevant row in Inventory. (3) Create a trigger “change_price” on table…arrow_forward10. Create a B-tree index on the customer’s Lastname column. Verify that the index exists byquerying the data dictionary. Remove the index from the databasearrow_forward
- Np Ms Office 365/Excel 2016 I NtermedComputer ScienceISBN:9781337508841Author:CareyPublisher:Cengage