ch02-minicases

# ch02-minicases - 2-1 Minicase 1 案例 1 Consider the Happy...

• 76
• 100% (1) 1 out of 1 people found this document helpful

This preview shows page 1 - 17 out of 76 pages.

2-1 Minicase 1 案例 1 Consider the Happy Cruise Lines Sailor file shown below. It lists all of the sailors on the company’s cruise ships by their unique sailor identification number, their name, the unique identification number of the ship they currently work on, their home country, and their job title.
2-2 Sailor Number Sailor Name Ship Number Home Country Job Title 1 00536 John Smith 009 USA Purser 2 00732 Ling Chang 012 China Engineer 3 06988 Maria Gonzalez 020 Mexico Purser 4 16490 Prashant Kumar 005 India Navigator 5 18535 Alan Jones 009 UK Cruise Director 6 20254 Jane Adams 012 USA Captain 7 23981 Rene Lopez 020 Philippines Captain 8 27467 Fred Jones 020 UK Waiter 9 27941 Alain DuMont 009 France Captain 10 28184 Susan Moore 009 Canada Wine Steward 11 31775 James Collins 012 USA Waiter Sailor Number Sailor Name Ship Number Home Country Job Title
2-3 a.i Describe the file’s record type .
2-4 Answer The record type consists of the following fields : Sailor Number, Sailor Name, Ship Number, Home Country, and Job Title.
2-5 a.ii Show a record occurrence .
2-6 Answer 00536, John Smith, 009, USA, Purser.
2-7 a.iii Describe the set or range of values that the Ship Number field can take.
2-8 Answer 000-999 as decimal integers.
2-9 a.iv Describe the set or range of values that the Home Country field can take.
2-10 Answer The names of all of the countries in the world.
2-11 b.i Assume that the records of the Sailor file are physically stored in the order shown. Retrieve all of the records of the file physically sequentially.
2-12 Answer The result will be the file, exactly as shown in the diagram. Using the records numbers shown to the left the records the order of the retrieved records will be 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12.
2-13 b.ii Retrieve all of the records of the file logically sequentially based on the Sailor Name field.
2-14 Answer Since we are being a little informal, the question can legitimately be asked whether the order will be by last name or, literally as shown in the diagram, by first name followed by last name . If it is by last name, then the order will be records 6, 2, 11, 9, 3, 5, 8, 4, 7, 12, 10, 1. If it is by first name followed by last name , then the order will be records 9, 5, 8, 11, 6, 1, 2, 3, 4, 7, 12, 10.
2-15 b.iii Retrieve all of the records of the file logically sequentially based on the Sailor Number field.
2-16 Answer Since the file is physically stored in order by the Sailor Number field, retrieving the file in order by the Sailor Number field is the same as retrieving the file in physical sequential order: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12.

Want to read all 76 pages?

Want to read all 76 pages?

#### You've reached the end of your free preview.

Want to read all 76 pages?

• Spring '14
• Tuple, Data hierarchy, Algebraic number field, Field extension

{[ snackBarMessage ]}

Upload your study materials now and get free access to over 25 million documents.

Upload now for FREE access Or pay now for instant access
###### "Before using Course Hero my grade was at 78%. By the end of the semester my grade was at 90%. I could not have done it without all the class material I found."
— Christopher R., University of Rhode Island '15, Course Hero Intern

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern