Notes
注意事项
How would you accomplish this task?
你该如何完成这项任务?
First ,you would probably go through the customer files in alphabetical order, foler by folder.
第一,你可能要按字母顺序仔细检查顾客文件,一个文件夹接着一个文件夹去查。
You would examine each invoice in the folders to determine if the amount is in excess of $2,500 and remove and copy each invoice that meets the criterion.
你还要查看文件夹内的每个发货票,以便确定其数额是否超过2500美元,对于满足要求的每个发货票要取出并加以复印。
You would then have to refill the copies you removed and risk misfiling them
然后你还必须把取出的部分重新归档
When you had examined all the customer folders and copied all the appropriate invoices.
当你检查了全部顾客文件夹并复印了全部需要复印的发货票,
you would then review the copies and put together your report.
你还要重新检查并且整理好
Imagine how much time this would take.
可以设想一下,做这些工作要花去多少时间。
If there are a lot of customers, you would need to spend hours if not days.
如果有大量顾客时,即使无需花好几天,也需要花好几个小时吧。
Now let's look at the situation in a different way.
现在我们用另一种方式来研究这个问题。
The environment is the same , except that ,instead of file cabinets.
环境情况不变以,只是取代文件柜的是,
you have a microcomputer or a terminal and DBMS software that has access to a customer database file as shown in the following .
你有了一台微型机或一台终端,以及可以访问顾客数据库的DBMS软件,这个顾客数据库文件如下面所示。
In this file a row of customer data is referred to as a record, and an individual piece of data within a record ,such as a name ,is referred to as a field.
在文件中,每一排顾客数据称为一个记录,记录内的单独数据段(如姓名)则称为一个字段。
To get the invoice data you need, you would do something like this.
为了获得你所需的发货票数据,你总要做如下一些事情。
Turn on the computer and the printer.
启动计算机及打印机。
start up the DBMS software
启动DBMS软件。
Give the command to open up the customer database file stored on your disk ,which is similar in concept to manually opening up the customer file in a filing cabinet.
发出命令,以便“打开”存储在磁盘中的顾客数据库文件,从概念上讲“打开”既类似于用手打开文件柜中的顾客文件。
Give the command to search all the records in the database file and display copies of the records that meet your criterion.
发出命令,以便搜索查找数据库文件中的全部记录,并显示合乎要求的记录内容。
that is the names of people with unpaid invoices greater than $2,500.
(即,发货票总金额超过2500元未付款人的姓名)。
If you were using dBASE IV , a popular microcomputer DBMS ,the command would look something like.
如果你一直使用的是Dbase 1v(一种在微机上使用的著名的DBMS),则命令会是:
If you were using SQL( Structured Query Language) the command would look like this.
如果你一直使用SQL(结构化查询语言),则命令会是:
In response to this command ,all the records in the file that have an invoice amount greater than $2,500 will be listed on the screen.
作为这些命令的回答,在文件的全部记录中,凡是多于2500元的发货票,均将在屏幕上显示出来。
The SQL command would also sort the listing into order by name.
(SQL命令将挑选的发货票按姓名进行排序)。
This whole procedure would take perhaps only five minutes or less.
全部过程可能只需要5分钟,甚至更少。