Modern Database Management 12th Edition Hoffer Solutions Manual Download
Modern Database Management 12th Edition Hoffer Solutions Manual Download
https://testbankfan.com/product/modern-database-management-12th-edition-
hoffer-solutions-manual/
https://testbankfan.com/product/modern-database-management-12th-
edition-hoffer-test-bank/
https://testbankfan.com/product/modern-database-management-10th-
edition-hoffer-solutions-manual/
https://testbankfan.com/product/modern-database-management-11th-
edition-hoffer-solutions-manual/
https://testbankfan.com/product/essentials-of-marketing-
management-1st-edition-marshall-test-bank/
Practical Financial Management 7th Edition Lasher
Solutions Manual
https://testbankfan.com/product/practical-financial-management-7th-
edition-lasher-solutions-manual/
https://testbankfan.com/product/precalculus-essentials-5th-edition-
blitzer-test-bank/
https://testbankfan.com/product/operations-and-supply-chain-
management-9th-edition-russell-solutions-manual/
https://testbankfan.com/product/computer-organization-and-design-
risc-v-1st-edition-patterson-solutions-manual/
https://testbankfan.com/product/essentials-of-radiographic-physics-
and-imaging-2nd-edition-johnston-test-bank/
On Cooking A Textbook of Culinary Fundamentals 6th Edition
Labensky Test Bank
https://testbankfan.com/product/on-cooking-a-textbook-of-culinary-
fundamentals-6th-edition-labensky-test-bank/
Chapter 6 1
Chapter Overview
This chapter describes in detail what has become the standard query language for
relational database management systems, SQL. Although SQL is illustrated in this
chapter primarily through a current Oracle version (MySQL and Microsoft Access SQL
are also sometimes displayed), SQL is a widely used language that is available on all
classes of computers and with many different DBMSs.
This chapter introduces SQL and emphasizes the Data Definition Language
(DDL) and Data Manipulation Language (DML) commands. Single table queries are
covered in this chapter, and multiple-table queries are covered in Chapter 7.
Several chapters contain important prerequisite material for this chapter. Chapter
4 introduces the relational model and provides much of the background for this chapter
(including an introduction to the Data Definition Language commands). The discussion
in Chapter 5 on indexes is also important because choosing primary and secondary key
indexes is one of the few, but crucial, internal database design choices for users of
relational systems.
Chapter Objectives
Specific student learning objectives are included at the beginning of the chapter. From an
instructor’s point of view, the objectives of this chapter are to:
1. Explain SQL and show the basic operators so that the student can anticipate the
capabilities of particular SQL-based systems.
2. Provide a historical perspective of the development of SQL and its continuing
development. This perspective illustrates the benefits and risks of adopting a
standard query language.
3. Show that SQL, although a standard and a high-level language, does have some
flaws, and that SQL must evolve to include additional features.
4. Explain and illustrate the power of relational views for simplifying relational
database processing.
5. Illustrate data definition language (DDL) commands for creating tables and views
as well as modifying and dropping tables.
6. Provide examples of single table SQL queries.
7. Provide some examples of the use of functions within SQL queries.
8. Show how to establish referential integrity using SQL.
9. Illustrate the use of the group by and order by clauses.
Key Terms
Classroom Ideas
1. Depending on how you choose to sequence the chapters of this book, you may want
to begin lecturing on this chapter by reviewing normalization principles and
discussing why one might want to implement a fully normalized database. See the
section “Denormalization” in Chapter 5 for background on this topic. The point is to
emphasize the difference between logical and physical database designs.
All the SQL queries in this chapter can be found in a Microsoft Access database
available from the publisher; you can show in class how Access SQL varies from
standard SQL, and you can show variations on the queries from this chapter. In
addition, a set of 40 lab exercise queries is available on
www.teradatauniversitynetwork.com for use with the Pine Valley Furniture
Company case. Many of these lab exercises are included already in this text. These
queries are designed to work with a database that is close to, but not exactly, the data
model in Figure 2-22.
3. Because many SQL systems include other modules (report writers, business graphics
routines, screen painters, and so forth), this chapter can be expanded to discuss
fourth-generation languages and systems prototyping. Explain that most packages
include capabilities and development tools that are more than simply a relational
DBMS and query language. If your school has joined the Oracle Academy, it may be
possible to demonstrate additional tools such as SQL Developer and/or
Designer/2000. Additionally, Oracle provides universal and free access to its
Express Edition with a Java-based application development environment which can
easily be used on individually-owned computers.
4. One interesting discussion item is the widespread and continued use of SQL in most
types of administrative systems, regardless of the system type and architecture. SQL
has been one of the most durable components of corporate computing architectures
during the past 20-30 years and it still does not show signs of aging.
6. The simplicity of SQL syntax leads some students to become overconfident of their
SQL prowess. It may help to develop some examples to demonstrate that logically
and syntactically correct SQL queries can be constructed that do not accomplish the
intended data manipulation and may be dangerously incorrect. For example, two
tables may be joined using common domains (for instance, positive integers) but
non-common roles (for example, two tables can be joined on equal values of
quantity-on-hand of a product and number of employees in a department). Such
potential problems arise because the relational data model uses implicit relationships,
not explicit ones. Stress the importance of testing a query on a small, tractable set of
data before using it in a production environment.
7. The capabilities and benefits of views are not as obvious to students as you might
expect. First, many relational systems place limitations on operations that may be
performed on views (for example, no or restricted modification). Second, views are
not just the relational term for temporary table or for subschemas (from the network
model); rather, views provide a capability for simpler query writing for casual users.
Finally, views may have negative performance implications compared to temporary,
intermediate tables explicitly created by a prewritten procedure. These points should
be emphasized in lectures or assignments. Consider having students create both a
view and a temporary table (or materialized view) in SQL. In most SQL systems, a
temporary table can be created by the use of a SAVE or KEEP clause at the end of a
query, or one can use a CREATE TABLE command that has a query (rather than
column definitions) as its object. Then, the same query can be run and timed against
both the view and temporary tables. As another alternative, have students derive the
view table as part of the FROM clause of a query. One way to estimate the timing of
each approach, given small data sets, is to use the EXPLAIN command (or similar
command with your RDBMS) on each version of the query to show students how the
query would be processed using each approach.
a. Base table. A table in the relational data model containing inserted raw data
that is likely to correspond to one physical file in secondary storage. The base
table is also referred to as one of the objects—such as the base tables, views,
constraints, and so on—which have been defined for a particular database by a
particular user, who owns the objects in the schema.
d view
h referential integrity constraint
c dynamic view
i materialized view
j SQL:2011
e null value
k scalar aggregate
a vector aggregate
b catalog
f schema
g host language
a. Base table; view. A view is a virtual table and is often part of an external
database. In contrast to a defined base table (relation), a view is not
permanently represented in storage. A view definition is stored, and the
contents of the view are calculated each time the view is referenced in a
query. A view may join multiple tables or views together and may contain
derived (or virtual) columns, while base tables cannot. In comparison to a
temporary real table, a view consumes very little storage space. A view is
costly (compared to a dynamic, materialized view), however, because its
contents must be calculated each time that it is requested.
b. Dynamic view; materialized view. Dynamic views are not a temporary table
but are materialized from an SQL query that uses the view definition that is
stored in the system catalog. Materialized views exist as a table and, thus,
must be kept synchronized with their associated base tables.
c. Catalog; schema. Schema is a structure that contains descriptions of objects
created by a user, such as base tables, views, constraints, and so on. These
objects have been defined for a particular database by a particular user, who
owns those objects in the schema. The catalog is a set of schemas, which,
when put together, constitute a description of a database. (If more than one
user has created objects in the database, combining information about all their
schemas will yield information for the entire database.)
manipulate, and query phenomena related to data values that change over time.
Temporal extensions are discussed at a more detailed level in Chapter 7.
Describe a relational DBMS (RDBMS), its underlying data model, data storage
structures, and manner of establishing data relationships:
a. The data definition language (DDL) commands of SQL are used to define a
database, including its creation and the creation of its tables, indexes, and
views. Referential integrity is also established through DDL commands.
CREATE/DROP DICTIONARY, CREATE/DROP TABLE, ALTER
TABLE, CREATE/DROP INDEX, CREATE/DROP VIEW are examples of
DDL commands.
b. The data manipulation (DML) commands of SQL are used to load, update,
and query the database through the use of the SELECT command. (START
TRANSACTION, COMMIT WORK, ROLLBACK WORK, INSERT,
UPDATE, and DELETE are examples of DML commands.)
c. Data control language (DCL) commands are used to establish user access to
the database through the GRANT, ADD USER, and REVOKE commands.
Reasons to create a view using SQL and how a view can be used to reinforce data
security:
a. Views may simplify query commands, provide valuable data security, and
enhance programming productivity for a database.
b. Tables and columns that are not included in a view will not be obvious to the
user of the view. Restricting access to a view with GRANT and REVOKE
statements (security statements) adds a further layer of security. It should not
be regarded as the primary security layer.
In general, update operations to data in a view are permitted as long as the update
is unambiguous in terms of data modification in the base table. However, when
the CREATE VIEW statement contains any of the following situations, that view
may not be updated directly.
a. The SELECT clause includes the keyword DISTINCT.
b. The SELECT clause contains expressions, including derived columns,
aggregates, statistical functions, and so forth.
c. The FROM clause, a subquery, or a UNION clause references more than one
table.
d. The FROM clause or a subquery references another view, which is not
updateable.
e. The CREATE VIEW command contains an ORDER BY, GROUP BY, or
HAVING clause.
When more than one program uses a view on the same base table, changes in all
the applications that relate to this particular base table will require only re-
creation of the view (outside the applications themselves). Views require
considerable run-time computer processing because the virtual table of a view is
recreated each time the view is referenced. Therefore, referencing a base table
through a view rather than directly can add considerable time to query processing,
depending on the query. This additional operational cost must be balanced against
the potential application maintenance savings from a view. A view also simplifies
query writing because queries written against the view refer to only one (virtual)
table, rather than several base tables.
Placing the ID of the owner prior to the table name and attribute name indicates
ownership of a table. For example, if the user with the User_ID of ORTEGA
owns the CUSTOMER_T table, that ownership would be indicated as
ORTEGA.CUSTOMER_T. In order for one user to be allowed to use a table in
the database owned by another user, the non-owner user must be granted
authorization to use it, usually by the database administrator.
a. Attributes are displayed in columns in the sequence in which they are listed in
the SELECT list unless the SELECT list is *, in which case all attributes from
the referenced tables are displayed in the sequence in which they are defined.
b. Use AS to specify column heading labels, e.g., SELECT CUST.
CustomerName AS NAME will result in a column heading label NAME
instead of CustomerName.
COUNT, COUNT DISTINCT, and COUNT(*) in SQL and the results generated
when using these:
a. COUNT tallies only those rows that contain a value; it ignores all null values.
b. COUNT DISTINCT does not return a count on all values; it only tallies once
if more than one row has equal values.
c. COUNT (*) counts all rows regardless of whether any of the rows contain null
values.
d. If we never use NULL values, COUNT and COUNT(*) will return the same
results. If our table includes no duplicates in the considered attribute values,
COUNT and COUNT DISTINCT will have the same meaning.
Evaluation order for the Boolean operators (AND, OR, NOT) in an SQL
command; getting the operators to work in the order that you want:
Only those columns that have a single value for each group can be included.
The HAVING clause is useful when you need to select results based upon
qualifications on an aggregation, such as a characteristic of a group. For example,
if we have a table with transactional sales data for salespeople, we may want to
sum up the total sales for a given period of time (an aggregate). We may then
want to produce a list of only salespeople who sold more than a certain amount,
say $1,000. This can be done using the HAVING clause.
IN operator usage:
The IN operator is used in conjunction with the WHERE clause. A set of valid
selections for the IN operator within parentheses follows the operator [e.g., IN
('WA', 'CA')]. The OR operator can be used to perform the same operation as the
IN operator. For example, if part of our WHERE clause is State IN ('MA', 'NH'),
this could be substituted with State = 'MA' OR State = 'NH'.
Determining the order in which the rows appear in the SQL query response set
The ORDER BY clause can be added to an SQL query to determine the order in
which the rows appear in the final response set.
The identity column creates a numeric sequence. For example, if we create the
following table:
then the first record added to Test1_T table will have 5 as its value for the ID
column. Subsequent record IDs will be incremented by 2.
Prior to SQL:2006 and SQL:2008, one had to use both insert and update to update
and merge data into a table. The Merge command allows one to do this in a single
step. A common use for this would be updating master table from a transaction
table where one might want to update records or create new records in the master
table based upon what was done in the transaction table. Let’s take a look at an
example: Suppose that we have an item table and a shipment table. The Item table
contains all of the items and the Shipment table contains items received by the
company.
Item Table
ItemNo Description Quantity
on Hand
342 MacBook Pro 10
345 Lenovo PC 55
346 4GB Memory 100
347 500GB HD 6
Shipment Table
ItemNo Description Quantity
Received
342 MacBook Pro 1
345 Lenovo PC 5
347 500GB HD 3
352 1TB External Drive 4
Notice that there is one additional item in the Shipment table. Now, let’s write the
merge statement to update the Item table. If the record exists in Item, then we will
add to the quantity on hand. If it does not, then we will add the record.
In a CREATE TABLE command, the CHECK clause allows for validation rules
for values to be inserted into the database, such as only allowing the Product_T
table to have rows of products that meet a checklist of certain ProductFinish
values (e.g., such as Cherry, Natural Ash, White Ash, Red Oak, Natural Oak, and
Walnut). In a CREATE VIEW command, the WITH CHECK OPTION ensures
that data entered into the database through a View meets the specifications stated
in the WITH CHECK OPTION element of the View definition. For example,
when a View is created with a criterion (or criteria) specification (e.g., all
products with price > $300) and the WITH CHECK OPTION enabled, any SQL
UPDATE or INSERT commands against the View that would violate the criterion
of Price needing to be $300 or more would be rejected.
The ALTER command may be used to add new columns, change existing
columns (name, data type, length, constraints, and default values), delete columns,
add constraints, and delete constraints of a Table. The ALTER command may not
be used with Views, nor can the ALTER command change the order of columns
within a Table.
This difference is relevant for aggregate queries using GROUP BY because that is
the context in which HAVING is used. WHERE clause limits the number of rows
that will be considered in the processing specified in the SQL query, whereas
HAVING is used to limit output rows (summarized groups) based on criteria that
apply to aggregate function values. For example, let’s assume that we have
products and product lines in a simple database, and we want to know the average
product price by product line but limit the results to a) only to those products that
cost more than $1,000 and b) to those product lines where the average price is
higher than $10,000. The following query achieves that:
In this case, WHERE limits the query to consider only those Products that cost
more than $1,000 and HAVING limits the output to those Product lines that have
an average ProdPrice greater than $10,000.
Yes, a query may use both the WHERE and HAVING clauses. The WHERE
clause would restrict which rows are included for processing by the query. The
HAVING clause (used in conjunction with a GROUP BY clause) determines
which summarized groups are included in the result set.
Note to Instructor: The solutions that include SQL statements are not intended
as the definitive answer to the questions, but as possible solutions. Instructors and
students will approach the problems using different SQL capabilities, achieving
results that are also correct.
Solutions are presented with SQL syntax that should work in most Oracle
installations (unless noted otherwise; for example, some examples follow the MS
Access syntax). Solutions may need to be modified for a particular Oracle
installation or if you are using a different relational database management system
(e.g., Teradata) to illustrate the use of SQL commands. The solutions in this
chapter and the following chapter use the naming conventions for tables,
relations, attributes/columns, and views as shown in the textbook chapters,
although Oracle SQL is not Upper/Lower case sensitive except when querying
metadata (e.g., table names).
Database descriptions:
Note: A particular SQL system may restrict the length of column names or may
not permit embedded spaces in names. The following answer may not be
acceptable to the SQL system you use; please modify the grammar accordingly.
CONSTRAINT StudentIsRegistered_FK
FOREIGN KEY(StudentID)
REFERENCES Student(StudentID),
CONSTRAINT CourseIsRegistered_FK
FOREIGN KEY (SectionNo)
REFERENCES
Section(SectionNo));
In its current form, the data is fully normalized. The question referred to an older
form of the database.
Creating a view
See the SECTION_FK constraint in the DDL for the SECTION table in Problem
and Exercise 6-34 above.
a.
a.
UPDATE Course_T
SET CourseName = 'Introduction to Relational Databases'
WHERE CourseID = 'ISM 4212';
SQL queries
a.
SELECT FacultyName
FROM Faculty_T
WHERE FacultyID = 4756;
c.
SELECT MIN(SectionID)
FROM Registration_T
WHERE Semester = 'I-2016';
SQL queries
a.
SELECT COUNT(*)
FROM Registration_T
WHERE Section = 2714
AND Semester = 'I-2015';
b.
SELECT FacultyID,CourseID,DateQualified
FROM Qualified_T
WHERE DateQualified >= '01-JAN-2008';
SQL queries
a. We assume all the question wishes in the result set are the Student IDs. The
Database course is ISM 4212, which is Section 2714 in the Registration_T
table, and the Networking course is ISM 4930, which is Section 2715 in the
Registration_T table:
SELECT StudentID,COUNT(*)
FROM Registration_T
SELECT FacultyID,COUNT(*)
FROM Qualified_T
WHERE CourseID IN ('ISM 3113', 'ISM 3112')
GROUP BY InstructorID
HAVING COUNT(*) = 1;
c. Using Chapter 6 SQL tools, a user could use two single table queries over the
SECTION table and then manually inspect the results to find the courses that
are taught in first semester but not in the second semester. This manual
inspection solution works moderately well when there are few rows in the
tables. Another possible manual solution is to list all the courses sorted by
CourseID and Semester from the SECTION table, and then manually inspect
the entries to find those with only first semester offerings. Again, this
approach works moderately well if there are few rows in the tables.
Using some Chapter 7 tools, the following query could be used to find the
requested information from the database:
SQL queries
a.
SELECT StudentName
FROM Student_T
ORDER BY StudentName;
c.
SELECT SectionNo,Semester,StudentID
FROM Registration_T
WHERE Semester = 'I-2015'
ORDER BY SectionNo,Semester,StudentID;
d.
SELECT CourseID,CourseName
FROM Course_T
ORDER BY CourseID ASC;
SQL queries
a.
SELECT SectionNo
FROM Section_T
WHERE CourseID = 'ISM 3113' AND
Semester = 'I-2015';
b.
SELECT CourseID, CourseName
FROM Course_T
WHERE CourseName LIKE 'Data%';
c.
SELECT FacultyID
FROM Qualified_T
WHERE CourseID IN ('ISM 3112', 'ISM 3113')
GROUP BY FacultyID
HAVING COUNT(CourseID)>1;
d.
SELECT FacultyID
FROM Qualified_T
WHERE CourseID IN ('ISM 3112', 'ISM 3113') AND
DateQualified > '31-DEC-2005'
GROUP BY FacultyID
HAVING COUNT(CourseID)>1;
e.
This query requires the missing Assignment table and use of data from multiple
tables
SELECT FacultyID
FROM Assignment_T
WHERE Semester = 'II-2015' AND
SectionNo IN (
SELECT SectionNo
FROM Section_T
WHERE CourseID = 'ISM 4212');
SELECT TutorID
FROM Tutor
WHERE Status = 'Active';
SQL queries
SELECT AVG(Read)
FROM Student;
Query: List the IDs of the tutors who are currently tutoring more than one
student.
SELECT TutorID
FROM MatchHistory
GROUP BY TutorID
HAVING COUNT(StudentID)>1;
Query: What are TutorIDs for tutors who have not yet tutored anyone?
Using Chapter 6 tools, a user could formulate two single table queries over the
database and then manually inspect the query results to find the required
information. For instance, a query over the TUTOR table will provide TutorIDs
of all Tutors and a query of DISTINCT TutorIDs from the MATCH_HISTORY
table will provide a listing of all currently matched Tutors. By manual inspection
of these two query result lists, one can find the “missing” TutorIDs from the
MATCH_HISTORY table. For a database such as this one, with a small number
of rows, a user could still find the information easily. As tables grow in size, such
a multiple step manual inspection process becomes less feasible as a practical
matter.
Using Chapter 7 tools, the following query could be used to get the information:
SELECT TutorID
FROM Tutor
WHERE TutorID NOT IN
(SELECT TutorID FROM MATCH_HISTORY);
Query: How many students are matched with someone in first five months of
year?
SELECT COUNT(StudentID)
FROM Match_History
WHERE StartDate BETWEEN '01-JAN-2015' AND '31-MAY-2015';
Note to Instructor: For 6-51 and 6-53, be sure the student realizes that a null
value in ENDDATE means that a student is still studying in the program and
should be included in the calculation. This is a good opportunity for the student to
discover that a calculated field can be quite useful where null values can be
expected. You may want to emphasize that this query will not update the base
table and these null values will remain until a student leaves the program.
This answer is shown in MS ACCESS SQL and uses the NZ function, which is
not covered in the text, to deal with the null dates. If no date is entered as an end
date in the dialog box, today’s date is inserted automatically for null values. As
the NZ function is used here, it will return the number of days the student has
studied into the calculated field.
Query: How long had each student studied in the adult literacy program?
Query: Which tutors have a Dropped status and have achieved their certification
after 4/01/2015?
SELECT TutorID
FROM Tutor
WHERE Status = 'Dropped' AND
CertDate > '1-APR-2015';
Query: What is the average length of time a student stayed (or has stayed) in the
program?
This query needs to use the TotalDays information calculated in 6-53, but as the
average function aggregates all rows, a two-step query will be needed to complete
the problem. This problem also demonstrates using a query as the base for another
query rather than working from a base table.
SELECT DateDiff('d',[StartDate],NZ([EndDate], NZ
[Enter date for blank records], Date()))) AS
TotalDays
FROM Match_History;
b. Query:
Note to instructor: Problems and Exercises 6-54 – 6-85 are based on the
extended version of the Pine Valley Furniture Company database. (BigPVFC.mdb
is the MS Access file version of this database; this is also available on Teradata
student resources.) Please note that this version of the database has a different
structure than that in the textbook version of the database (e.g., the salesperson
information is in the extended version but not in the textbook version). Some of
the field names may also have changed due to the version of the database you are
using due to the reserved words of the DBMS. When you first use the database,
check the table definitions to see what the exact field names and table structures
are for the DBMS that you are using.
Students should answer this exercise using INSERT commands to enter new rows
into the Order_T and OrderLine_T tables.
PVFC queries:
Although the data in this table is sparsely populated and the answers to these
questions can be found by simple inspection of the table values, encourage the
students to write SQL to derive the results:
a.
SELECT COUNT(*)
FROM WorkCenter_T;
b.
SELECT WorkCenterLocation
FROM WorkCenter_T;
Query:
SELECT EmployeeID,EmployeeName
FROM Employee_T
WHERE EmployeeName LIKE 'L%';
Query:
SELECT EmployeeName
FROM Employee_T
WHERE EmployeeDateHired BETWEEN '01-JAN-2005'
AND '31-DEC-2005';
Query:
OR
Note: The query shown here is an MS-Access query. If using Oracle, simply
replace the double quotes with single quotes.
Query:
Material ID, name, material, standard cost, and thickness for raw materials made
of cherry, pine, or walnut. Order the list by material, standard cost, and
thickness:
Note: The query shown here is an MS-Access query. If using Oracle, simply
replace the double quotes with single quotes. Also, an alternative solution is to
use the OR operator rather than the IN operator, as in Problem & Exercise 6-60
above.
Query:
Display the product line ID and the average standard price for all products in
each product line:
Query:
For every product that has been ordered, display the product ID and the total
quantity ordered (label this result TotalOrdered). List the most popular product
first and the least popular last:
Query:
Query:
Query:
Display the product ID and the number of orders placed for each product. Show
the results in decreasing order, and label result column NumOrders:
Query:
FROM OrderLine_T
GROUP BY ProductID
ORDER BY COUNT(ProductID) DESC;
SELECT Order_T.CustomerID,
COUNT(Order_T.OrderID) AS TotOrders
FROM Order_T
WHERE (((Order_T.OrderDate) Between #1/1/2015# AND
#12/31/2015#))
GROUP BY Order_T.CustomerID;
SELECT CustomerID,
COUNT(OrderID) AS TotOrders
FROM Order_T
WHERE OrderDate Between '01-Jan-2015' AND
'31-Dec-2015'
GROUP BY CustomerID;
Query:
Customer ID and total orders placed if more than two orders were placed:
Query:
All sales territories that have more than one salesperson: (Note: We also show
the number of salespeople for each territory.)
Query:
GROUP BY SalesTerritoryID
HAVING COUNT(SalespersonName) > 1;
Note: Because subqueries have not been covered yet, the student should just order
the query by the total orders and report on the top ProductID (or ProductIDs if
more than one):
Query:
SELECT ProductID,
COUNT(*) AS NumOrders
FROM OrderLine_T
GROUP BY ProductID
ORDER by COUNT(*) DESC;
Query:
Measured by average standard price, what is the least expensive product finish?
Query:
Note: This response includes the average prices for all finishes.
For every territory having more than one salesman, display SalesTerritoryID and
the number of salespersons in the territory:
Query:
Query:
MS-Access
SELECT SalespersonID, month(OrderDate) AS Month,
COUNT(OrderID) as TotalOrders
FROM Order_t
WHERE OrderDate BETWEEN #01/01/2015# and #12/31/2015#
GROUP BY SalespersonID, month(OrderDate)
ORDER BY SalespersonID,month(OrderDate);
Oracle
SELECT SalespersonID,
TO_CHAR(OrderDate, 'MON') AS Month,
COUNT(OrderID) AS TotalOrders
FROM Order_T
WHERE OrderDate BETWEEN '01-Jan-2015' AND
'31-Dec-2015'
GROUP BY
SalespersonID,TO_CHAR(OrderDate, 'MON')
ORDER BY
SalespersonID,TO_CHAR(OrderDate, 'MON');
Material name, material, and width for raw materials that are not cherry or oak
and whose width is greater than 10 inches.
Note: This query is in an Oracle format. If you want to use it with Access, please
replace the single quotes with double quotes.
Query:
Query:
Although not asked by the problem and exercise, an alternative solution might
sort the output, as follows:
Query:
Write the query to find the most recent date among orders:
SELECT MAX(OrderDate) AS MostRecent FROM Order_T;
Then, use this query as a derived table to access with the FROM clause:
SELECT OrderID, CustomerID, OrderDate,
(SELECT MAX(OrderDate) AS MostRecent FROM ORDER_T) AS
MostRecent
FROM Order_T;
CustomerID, number of orders from that customer, total number of orders from
all customers combined, and the ratio of that customer’s orders to all customer
orders:
Query:
"God keep you from the she-wolf, and from your heart's deep
desire!"
That is one of our old sayings here in Provence. I used to laugh at it
when I was young. I do not laugh at it now. When those words
come into my heart, and they come often, I go by the rough hard
way that leads upward to Notre Dame de la Garde until I come to
the Crime Cross—it is a wearying toil for me to get up that steep hill-
side, I am so stiff and old now—and there I cast fresh stones upon
the heap at the foot of the cross. Each stone cast there, you know,
is a prayer for forgiveness for some hidden crime: not a light fault,
but a crime. The stones must be little stones, yet the heap is very
wide and high—though every winter, when the great mistrals are
blowing across the Étang de Berre, the little stones are whirled away
down the hill-side. I do not know how this custom began, nor when;
but it is a very old custom with us here in Les Martigues.
Once in every year I go up to the Crime Cross by night. This is on All
Souls Eve. First I light the lamp over Magali's breast where she lies
sleeping in the graveyard: going to the graveyard at dusk, as the
others do, in the long procession that creeps up thither from the
three parts of our town—from Jonquières, and the Isle, and Ferrières
—to light the death-fires over the dear dead ones' graves. I go with
the very first, as soon as the sun is down. I like to be alone with
Magali while I light the little lamp that will be a guide for her soul
through that night when souls are free; that will keep it safe from
the devils who are free that night too. I do not like the low buzzing
of voices which comes later, when the crowd is there, nor the broken
cries and sobs. And when her lamp is lit, and I have lit my mother's
lamp, I hurry away from the graveyard and the moaning people—
threading my steps among the graves on which the lights are
beginning to glimmer, and through the oncoming crowd, and then by
the lonely path through the olive-orchards, and so up the stony
height until I come at last to the Crime Cross—panting, aching—and
my watch begins.
MARIUS
Up on that high hill-side, open to the west, a little of the dying
daylight lingers. Eastward, like a big black mirror, lies the great
étang; and far away across its still waters the mountain chain above
Berre and Rognac rises purple-grey against the darker sky. In the
west still are faint crimson blotches, or dashes of dull blood-red—
reflected again, and made brighter, in the Étang de Caronte: that
stretches away between the long downward slopes of the hills, on
which stone-pines stand out in black patches, until its gleaming
waters merge into the faint glow upon the waters of the
Mediterranean. Above me is the sanctuary of Notre Dame de la
Garde, a dark mass on the height above the olive-trees: of old a
refuge for sinful bodies, and still a refuge where sinful souls may
seek grace in prayer from their agony. And below me, on the slope
far downward, is the graveyard: where the death-fires multiply each
moment, as more and more lamps are lighted, until at last it is like a
little fallen heaven of tiny stars. Only in its midst is an island of
darkness where no lamps are. That is where the children lie
together: the blessed innocents who have died sinless, and who
wander not on All Souls Eve because when sweet death came to
them their pure spirits went straight home to God. And beyond the
graveyard, below it, is the black outspread of the town: its blackness
deepened by a bright window here and there, and by the few street
lamps, and by the bright reflections which shine up from the waters
of its canals.
Seeing all this—yet only half seeing it, for my heart is full of other
things—I sit there at the foot of the Crime Cross in the darkness,
prayerful, sorrowful, while the night wears on. Sometimes I hear
footsteps coming up the rocky path, and then the shadowy figure of
a man or of a woman breaks out from the gloom and suddenly is
close beside me—and I hear the rattle of little stones cast upon the
heap behind me, on the other side of the cross. Presently, the rite
ended, whoever it is fades back into the gloom again and passes
away. And I know that another sinful soul has been close beside my
sinful soul for a moment: seeking in penitent supplication, as I am
seeking, rest in forgiveness for an undiscovered crime. But I am sure
that none of them sees—as I see in the gloom there always—a
man's white face on which the moonlight is shining, and beyond that
white face the glint of moonlight on a raging sea; and I am sure that
on none of their blackened souls rests a burden as heavy as that
which rests on mine.
I am very weary of my burden, and old and broken too. It is my
comfort to know that I shall die soon. But, also, the thought of that
comfort troubles me. For I am a lone man, and childless. When I go,
none of Magali's race, none of my race, will be left alive here in Les
Martigues. Our death-fires will not be lighted. We shall wander in
darkness on All Souls Eve.
II
"God keep you from the she-wolf, and from your heart's deep
desire!"
My old mother, God rest her, said that to me when first she began to
see that my love was set on Magali—and saw, too, that I was
winning from Magali the love that belonged to Jan, who had her
promise.
"It is an old man's lifetime, mother," I said, "since a wolf has been
seen near Les Martigues." And I laughed and kissed her.
"Worse than a wolf is a heart that covets what it may not have,
Marius," she answered. "Magali is as good as Jan's wife, and you
know it. For a year she has been promised to him. She is my dead
sister's child, and she is in my care—and in your care too, because
you and she and I are all that is left of us, and you are the head of
our house, the man. You are doing wickedness in trying to take her
away from Jan—and Jan your own close friend, who saved your life
out of the sea. The match is a good match for Magali, and she was
contented with it until you—living here close beside her in your own
house—began to steal away her heart from him. It is rascal work,
Marius, that you are doing. You are playing false as a house-father
and false as a friend—and God help me that I must speak such
words to my own son! That is why I say, and I say it solemnly, 'God
keep you from the she-wolf, and from your heart's deep desire!' That
desire has no right to be in your heart, Marius. Drag it out of your
heart and cast it away!"
But I only laughed and kissed her again, and told her that I would
take good care of myself if a she-wolf tried to eat me—and so I went
away, still laughing, to my fishing in the Gulf of Fos.
But I did not laugh when I was alone in my boat, slipping down the
Étang de Caronte seaward. What she had said had made me see
things clearly which until then had been half hid in a haze. We had
slipped into our love for each other, Magali and I, softly and easily—
just as my boat was slipping down the étang. Every day of our lives
we were together, in the close way that housemates are together in
a little house of four rooms. Before I got up in the morning I could
hear her moving near me, only a thin wall between us; and her
movements, again, were the last sounds that I heard at night. She
waited on me at my meals. She helped my mother to mend my
clothes—the very patches on my coat would bring to my mind the
sight of her as she sat sewing at night beside the lamp. We were as
close together as a brother and a sister could be; and in my dulness
I had fancied for a long while that what I had felt for her was only
what a brother would feel.
What first opened my eyes a little was the way that I felt about it
when she gave her promise to Jan. For all our lives Jan and I had
been close friends: and most close since that day when the squall
struck our boats, as we lay near together, and I went overboard, and
Jan—letting his own boat take its chances—came overboard after
me because he knew that I could not swim. It was by a hair's-
breadth only that we were not drowned together. After we were safe
I told him that my life was his. And I meant it, then. Until Magali
came between us I would have died for him with a right good will.
After that I was ready enough that he should do the dying—and so
be gone out of my way.
When he got Magali's promise, I say, my ugly feeling against him
began. But it was not very strong at first, and I was not clear about
it in my own mind. All that I felt was that, somehow, he had got
between me and the sun. For one thing, I did not want to be clear
about it. Down in the roots of me I knew that I had no right to that
sunshine, and that Jan had—and I could not help thinking about
how he had come overboard after me and had held me up there in
the tumbling sea, and how I had told him that my life was his. But
with this went a little thin thought, stirring now and then in the
bottom of my mind though I would not own to it, that in giving him
my life—which still was his if he wanted it—I had not given him the
right to spoil my life for me while leaving me still alive. And I did my
best not to think one way or the other, and was glad that it all was a
blur and a haze.
And all the while I was living close beside Magali in that little house,
with the sound of her steps always near me and the sound of her
voice always in my ears. She had a very sweet voice, with a
freshness and a brightness in it that seemed to me like the
brightness of her eyes—and Magali's great black eyes were the
brightest eyes that ever I saw. Even in Arles, where all the women
are beautiful, there would be a buzz among the people lining Les
Lices when Magali walked there of a feast-day, wearing the beautiful
dress that our women wear here in Provence. To look at her made
you think of an Easter morning sun.
III
"God keep you from the she-wolf, and from your heart's deep
desire!"
My mother's words kept on ringing in my ears after I had left her.
Suddenly the haze was gone and I saw clearly—and I knew that my
heart's deep desire was to have Magali for my very own. And with
that sudden coming of clear sight I knew, too, that I could have her.
Out of the past came a crowd of memories which proved it to me. In
my dull way, I say, I had fancied that I loved Magali as a sister, and I
had tried to keep that fancy always by me in my haze. But with the
haze gone—swept away by my mother's words as the mistral
sweeps away our Mediterranean fogs—I knew that Magali never had
been the fool that I had been.
I remembered her looks and her ways with me from the very day
when she came to us, when she was just turned of sixteen: how she
used sometimes to lay her hand lightly on my shoulder, how she
would bend over to look at the net that I was mending until her hair
brushed against my cheek or my forehead, how she always was
bringing things to show me that I could not see rightly unless she
stood very close at my side, and most of all how a dozen times a day
she would be flashing at me her great black eyes. And I
remembered how moody and how strange in her ways she was just
before Jan got his promise from her; and how, when she told me
that her promise was given, she gave me a look like none that ever I
had from her, and said slowly: "The fisherman who will not catch any
fish at all because he cannot catch the fish he wants most—is a fool,
Marius!"
Yet even then I did not understand; though, as I say, my eyes were
opened a little and I had the feeling that Jan had got between me
and the sun. That feeling grew stronger because of the way that she
treated him and treated me. Jan was for hurrying the marriage, but
she kept him dangling and always was putting him off. As for me, I
got all sides of her moods and tempers. Sometimes she scarcely
would speak to me. Sometimes she would give me looks from those
big black eyes of hers that thrilled me through! Sometimes she
would hang about me in a patient sad way that made me think of a
dog begging for food. And the colour so went out of her face that
her big black eyes looked bigger and blacker still.
Then it was that I began to find in the haze that was about me a
refuge—because I did not want to see clear. I let my thoughts go
out to Magali, and stopped them before they got to Jan. It would be
time enough, I reasoned—though I did not really reason it: I only
felt it—to think about him when I had to. For the passing hours it
was enough to have the sweetness of being near Magali—and that
grew to be a greater sweetness with every fresh new day. Presently
I noticed that her colour had come back again; and it seemed to me
—though that may have been only because of my new love of her—
that she had a new beauty, tender and strange. Certainly there was
a new brightness, a curiously glowing brightness, in her eyes.
For Jan, things went hardly in those days. Having her promise, he
had rights in her—as we say in Provence. But he did not get many of
his rights. Half the time when he claimed her for walks on the hill-
sides among the olive-orchards, she would not go with him—
because she had her work to do at home, she said. And there was I,
where her work was, at home! For a while Jan did not see beyond
the end of his nose about it. I do not think that ever it crossed his
mind to think of me in the matter—not, that is, until some one with
better eyes than his eyes helped him to see. For he knew that I was
his friend, and I suppose that he remembered what I had told him
about my life being his. And even when his eyes were helped, he
would not at first fully believe what he must plainly have seen. But
he soon believed enough to make him change his manner toward
me, and to make him watch sharp for something that would give
him the right to speak words to me which would bring matters to a
fair settlement by blows. And I was ready, as I have said—though I
would not fairly own it to myself—to come to blows with him. For I
wanted him dead, and out of my way.
And so my mother's words, which had made me at last see clearly,
stayed by me as I went sailing in my boat softly seaward down the
étang. And they struck deeper into me because Jan's boat was just
ahead of mine; and the sight of him, and the thought of how he had
saved my life only to cross it, made me long to run him down and
drown him, and so be quit of him for good and all. I made up my
mind then that, whether I killed him or left him living, it would be I
who should have Magali and not he.
IV
"God keep you from the she-wolf, and from your heart's deep
desire!"
My mother said that again to me when I came home that night from
my fishing; and she said it to me often as the days went on. She
saw the change that had come to me, and she knew what was in my
soul. It is not wonderful, when you stop to think about it, that a
man's mother should know what is in his soul: for the body in which
that soul is, the living home of it, is a part of her own. And she grew
sad and weary-looking when she found that her words had no hold
on me, and there came into her eyes the sorrowful look that comes
into the eyes of old people who are soon to die.
But Magali's eyes were the only eyes that I cared for then, and they
seemed to me to grow brighter and brighter every day. When she
and I walked in the olive-orchards together in the starlight the glow
of them outshone the star-glow. It seemed to light up my heart.
I do not think that we talked much in those walks. I do not seem to
remember our talking. But we understood each other, and we were
agreed about what we were to do. I was old enough to marry as I
pleased, but Magali was not—she could not marry without my
mother's word. We meant to force that word. Some day we would
go off in my boat together—over to Les Saintes Maries, perhaps; or
perhaps to Marseille. It did not matter where we went. When we
came back again, at the end of two or three days, my mother no
longer could deny us—she would have to give in. And no one would
think the worse of Magali: for that is our common way of settling a
tangled love-matter here in Provence.
But I did not take account of Jan in my plans, and that was where I
made a mistake. Jan had just as strong a will as I had, and every bit
of his will was set upon keeping Magali for himself. I wanted her to
break with him entirely, but that she would not do. She was a true
Provençale—and I never yet knew one of our women who would rest
satisfied with one lover when she could have two. If she can get
more than two, that is better still. While I hung back from her,
Magali was more than ready to come to me; but when she found me
eager after her, and knew that she had a grip on me, she danced
away.
And so, before long, Jan again had his walks with her in the olive-
orchards by starlight just as I did, and likely enough her eyes glowed
for him just as they did for me. When they were off that way
together I would get into a wild-beast rage over it. Sometimes I
would follow them, fingering my knife. I suppose that he felt like
that when the turn was mine. Anyhow, the love-making chances
which she gave him—even though in my heart I still was sure of her
—kept me always watching him; and I could see that he always was
watching me. Very likely he felt sure of her too, and that was his
reason—just as it was my reason—for not bringing our matter to a
fighting end. I was ready enough to kill him, God knows. Unless his
eyes lied when he looked at me, he was ready to kill me.
And in that way the summer slipped past and the autumn came, and
neither of us gained anything. I was getting into a black rage over it
all. Down inside of me was a feeling like fire in my stomach that
made me not want to eat, and that made what I did eat go wrong.
My poor mother had given up trying to talk to me. She saw that she
could not change my way—and, too, I suppose that she pretty well
understood it all: for she had lived her life, and she knew the ways
of our men and of our women when love stings them here in
Provence. Only, her sadness grew upon her with her hopelessness.
What I remember most clearly as I think of her in those last days is
her pale old face and the dying look in her sorrowful eyes.
But seeing her in that way grief-struck only made my black rage
blacker and the fire in my stomach burn hotter. I had the feeling that
there was a devil down there who all the time was getting bigger
and stronger: and that before long he and I would take matters in
hand together and settle them for good and all. As for keeping on
with things as they were, it was not to be thought of. Better than
much more of such a hell-life would be ending everything by killing
Jan.
What made me hang back from that was the certainty that if I did
kill him—even in a fair fight, with his chance as good as mine—I
would lose Magali beyond all hope: for the gendarmes would have
me away in a whiff to jail—and then off would go my head, or, what
would be just as bad, off I would go head and all to Cayenne. It was
no comfort to me to know that Magali would almost cry her eyes out
over losing me. Of course she would do that, being a Provençale.
But before her eyes were quite out she would stop crying; and then
in a moment she would be laughing again; and in another moment
she would be freshly in love once more—with some man who was
not murdered and who was not gone for his lifetime over seas. And
all that, also, would be because she was a Provençale.
All the devils are let loose on earth on All Souls Eve—that is a fact
known to everybody here in Provence. But whether it was one of
those loosed devils, or the devil that had grown big in my own
inside, that made me do what I did I do not know. What I do know,
certainly, is that about dusk on All Saints Day the thought of how I
could force things to be as I wanted them to be came into my heart.
My thought was not a new thought, exactly. It was only that I would
do what we had planned to do to make my mother give in to us: get
Magali into my boat and carry her off with me for a day or two to
Les Saintes. But it came to me with the new meaning that in that
way I could make Magali give in to me too. When we came back she
would be ready enough to marry me, and my mother would be for
hurrying our marrying along. It all was as plain and as sure as
anything could be. And, as I have said, nobody would think the
worse of Magali afterward; because that way of cutting through such
difficulties is a common way with us in Provence.
And All Souls Eve was the time of all times for doing it. The whole
town is in commotion then. In the churches, when the Vespers of All
Saints are finished, the Vespers of the Dead are said. Then, just
after sunset, the streets are crowded with our people hurrying to the
graveyard with their lanterns for the graves. Nothing is thought
about but the death-fires. From all the church towers—in Jonquières,
in the Isle, in Ferrières—comes the sad dull tolling of bells. After
that, for an hour or more, the town is almost deserted. Only the very
old, and the very young, and the sick with their watchers, and the
bell-ringers in the towers, are left there. Everybody else is in the
graveyard, high up on the hill-side: first busied in setting the lights
and in weeping over dead loved ones; and then, when the duty to
the dead ones is done with, in walking about through the graveyard
to see the show. In Provence we take a great interest in every sort
of show.
Magali and I had no death-fires to kindle, for in the graveyard were
no dead of ours. Our people were of Les Saintes Maries, and there
their graves were—and my father, who was drowned at his fishing,
had no grave at all. But we went always to the graveyard on All
Souls Eve, and most times together, that we might see the show
with the others and enjoy the bustle of the crowd. And so there was
nothing out of the common when I asked her to come with me; and
off we started together—leaving my old mother weeping at home for
my dead father, who could have no death-fire lit for him because his
bones were lying lost to us far away in the depths of the sea.
Our house was in the eastern quarter of the town, in Jonquières. To
reach the graveyard we had to cross the Isle, and go through
Ferrières, and then up the hill-side beyond. But I did not mean that
we should do that; and when we had crossed the Canal du Roi I said
to Magali that we would turn, before we went onward, and walk
down past the Fish-market to the end of the Isle—that from there
we might see the lights glowing in the dusk on the slope rising
above us black against the western sky. We had done that before—it
is a pretty sight to see all those far-off glittering points of light
above, and then to see their glittering reflections near by in the
water below—and she willingly came with me.
But I had more in view. Down at the end of the Isle, along with the
other boats moored at the wharf there to be near the Fish-market,
my boat was lying; and when we were come close to her I said
suddenly, as though the thought had entered my head that minute,
that we would go aboard of her and run out a little way—and so see
the death-fires more clearly because they would be less hidden by
the shoulder of the hill. I did not have to speak twice. Magali was
aboard of the boat on the instant, and was clapping her hands at the
notion—for she had, as all our women have, a great pleasure in
following any sudden fancy which promises something amusing and
also a little strange. And I was quick after her, and had the lines cast
off and began to get up the sail.
"Oh," she said, "won't the oars do? Need we bother with the sail for
such a little way?"
But I did not answer her, and went on with what I was doing, while
the boat drifted quickly out from land before the gusts of wind which
struck us harder and harder as we cleared the point of the Isle. Until
then I had not thought about the weather—my mind had been full of
the other and bigger thought. The gusts of wind waked me up a
little, and as I looked at the sky I began to have doubts that I could
do what I wanted to do; for it was plain that a gale was rising which
would make ticklish work for me even out on the Gulf of Fos—and
would make pretty near impossible my keeping on to Les Saintes
over the open sea. And I had about made up my mind that we must
go back, and that I must carry out my plan some other time, when
there came a hail to us from the shore.
"Where are you going?" called a voice—and as we turned our looks
shoreward there was Jan. He had been following us, I suppose—just
as I sometimes had followed him.
Before I could answer him, Magali spoke. "We are going out on the
water to see the death-fires, Jan," she said. "We are going only a
very little way."
Her words angered me. There was something in them that seemed
to show that he had the right to question her. That settled me in my
purpose. Storm or no storm, on I would go. And I brought the boat
up to the wind, so as to lay our course straight down the Étang de
Caronte, and called out to him: "We are going where you cannot
follow. Good-bye!"
And then a gust of wind heeled us over, and we went on suddenly
with a dash—as a horse goes when you spur him—and the water
boiled and hissed under our bows. In another half-minute we were
clear of the shelter of the point, and then the wind came down on us
off the hills in a rush so strong that I had to ease off the sheet
sharply—and I had a queer feeling about what was ahead of me out
on the Gulf of Fos.
"Marius! Marius! What are you doing?" Magali cried in a shiver of
fright: for she knew by that time that something was back of it all in
my mind. As she spoke I could see through the dusk that Jan was
running up the sail of his boat, and in a minute more would be after
us.
"I am doing what I ought to have done long ago," I said. "I am
taking you for my own. There is nothing to fear, dear Magali. You
shall not be in danger. I had meant to take you to Les Saintes. But a
gale is rising and we cannot get to Les Saintes to-night. We will run
across the Gulf of Fos and anchor in the Grau de Gloria. There is a
shepherd's hut near the Grau. I will make a fire in it and you can
sleep there comfortably, while I watch outside. After all, it makes no
difference where we go. I shall have carried you off—when we go
back you must be my wife."
She did not understand at first. She was too much frightened with
the suddenness of it all, and with the coming of Jan, and with the
boat flying on through the rushing of the wind. I looked back and
saw that Jan had got away after us. Dimly I could make out his sail
through the dusk that lay thick upon the water. Beyond it and above
it was a broad patch of brightness where all the death-fires were
burning together in the graveyard. We had come too far to see any
longer those many points of light singly. In a mass, they made
against the black hill-side a great bright glow.
VI
"God keep you from the she-wolf, and from your heart's deep
desire!"
My mother's words seemed to sound in my ears loudly, coming with
the rush of wind that eddied around me out of the sail's belly. They
gave me a queer start, as the thought came with them that here at
last my heart's deep desire would be mine presently—if only I could
snatch it and keep it from the she-wolf of the sea.
Magali was silent—half standing, half sitting, against the weather
side of the boat, close in front of me as I stood at the tiller with the
sheet in my hand. She had got over her fright. I could tell that by
the brightness of her eyes, and by the warm colour in her cheeks
that I had a glimpse of as we flashed past the break in the hills
where the Mas Labillon stands. And in that moment while the dusk
was thinned a little I could see, too, that she was breathing hard. I
know what our women are, and I know what she was feeling. Our
women like to be fought for, and any one of them gladly would have
been in Magali's place—with the two strongest and handsomest men
in Les Martigues in a fair way to come to a death-grip for her in the
whirl of a rising storm.
Back in the dusk, against the faint glow of the death-fires, I could
see the sail of Jan's boat dipping and swaying with the thrusts of the
wind-gusts as it came on after me. It had gained a little; and I knew
that it would gain more, for Jan's boat was a speedier boat than
mine on the wind. Close-hauled, I could walk away from him; but in
running down the Étang de Caronte I had no choice in my sailing.
Out on the Gulf of Fos, if I dared take that chance, and if he dared
follow me, I could bear up to windward and so shake him off—
making for the Anse d'Auguette and taking shelter there. But even
my hot blood chilled a little at the thought of going out that night on
the Gulf of Fos. When we were down near the end of the étang—
close to the Salines, where it is widest—the wind that pelted down
on us from the hills was terribly strong. It was hard to stand against
even there, where the water was smooth. Outside, it would be still
stronger, and the water would be all in a boil. And at the end, to get
into the Anse d'Auguette, we should have to take the risk of a
roaring sea abeam.
But any risk was better than the risk of what might happen if Jan
overhauled me. Now that I fairly had Magali away from him, I did
not want to fight him. What might come in a fight in rough water—
where the winds and the waves would have to be reckoned with,
and with the most careful reckoning might play tricks on me—was
too uncertain; while if I could stand him off and get away from him,
so that even for one night I could keep Magali with me, the game
would be won. After that, if he wanted it, I would fight him as much
as he pleased.
The thought that I would win—in spite of Jan and in spite of the
storm, too—made all my blood tingle. More by habit than anything
else I sailed the boat: for my eyes were fixed on Magali's eyes,
shining there close to me, and my heart was full of her. We did not
speak, but once she turned and looked at me—bending forward a
little, so that her face was within a foot of mine. What she saw in my
eyes was so easy to read that she gave all at once a half-laugh and
a half-sob—and then turned away and peered through the blustering
darkness toward Jan's sail. Somehow, the way she did that made me
feel that she was holding the balance between us; that she was
waiting—as the she among wild beasts waits while the males are
fighting for her—for the stronger of us to win. After that I was ready
to face the Gulf of Fos.
The time for facing the gulf was close on me, too. We had run
through the canal of the Salines and were out in the open water of
Bouc—the great harbour at the mouth of the étang. The gale roared
down on us, now that there was little land to break it, and we began
to hear the boom of the waves pounding on the rocks outside. I
luffed well into the wind and bore up for the narrows opening
seaward where the Fort de Bouc light-house stands. The water still
was not rough enough to trouble us. It would not be rough until we
were at the very mouth of the narrows. Then, all at once, would
come the crush and fury of the wind and sea. I knew what it would
be like: and again a chill shot through me at the thought of risking
everything on that one great chance. But I had one thing to comfort
me: the moon had risen—and while the light came brokenly, as the
clouds thinned and thickened again, there was brightness enough
even at the darkest for me to lay a course when I got out among the
tumbling waves. Yet only a man half mad with passion would have
thought of fronting such a danger; and even I might have held back
at the last moment had I not been stung to go on.
Jan had so gained on me in the run down the étang that as we
came out from the canal of the Salines his boat was within less than
a dozen rods of mine; and as I hauled my sheet and bore up for the
narrows he shot down upon us and for a moment was almost under
our stern. And at that Magali gave a little jump and a half-gasp, and
laid her hand upon mine, crying: "Marius! Quick! Sail faster! He will
take me from you! Get me away! Get me away!"
And then I knew that she no longer balanced us, but that her heart
was for me. After that I would have faced not only the Gulf of Fos
but the open Mediterranean in the worst storm that ever blew.
VII
"God keep you from the she-wolf, and from your heart's deep
desire!"
The words were in my ears again as we went flying on toward the
narrows—with the reflection of the flame in the light-house making a
broad bright path for us, and the flame itself rising high before us
against the cloud-rack like a ball of fire. But God was not with me
then, and I gave those warning words no heed. I was drunk with the
gladness that came to me when Magali made her choice between
us; and all that I thought was that even if we did go down together,
out there in the Gulf of Fos, I still would be keeping her from Jan
and holding her for my own. That there might be any other ending
for us never crossed my mind.
Jan did not think, I suppose, that I would dare to go outside the
harbour. He was in a rage too, no doubt; but, still, he must have
been a good deal cooler than I was—for a rage of hate does not boil
in the very bones of a man, as a rage of love does—and so cool
enough to know that it was sheer craziness to take a boat out into
that sea. What I meant to do must have come to him with
suddenness—as we drew so close to the light-house that the flame
no longer was reflected ahead of us, and the narrows were open
over my starboard bow, and I let the boat fall off from the wind and
headed her into the broken water made by the inroll of half-spent
waves. In my run close-hauled I had dropped him, but not so much
as I thought I should, and as I came on the wind again—and hung
for a moment before gathering fresh headway—he ranged up once
more within hail.
"Where are you going? Are you crazy?" he called out—and though
he must have shouted with all the strength of his big lungs his voice
came thin through the wind to us, and broken by the pounding of
the sea.
"Where you won't dare to follow!" I called back to him—and we
went rushing on below the big old fort, that carries the light on its
tower, through the short passage between the harbour and the Gulf
of Fos.
Something he answered, but what it was I do not know: for as we
cleared the shelter of the fort—but while the tail of rock beyond it
still was to windward, so that I could not luff—down with a crash on
us came the gale. I could only let fly the sheet—but even with the
sheet all out over we went until the sail was deep in the water, and
over the leeward gunwale the waves came hissing in. I thought that
there was the end of it; but the boat had such way on her that even
on her beam ends and with the sail dragging she went on until we
had cleared the rocks; and then I luffed her and she rose slowly, and
for the moment was safe again with her nose in the wind.
Magali's face was dead white—like a dead woman's face, only for her
shining eyes. She fell to leeward as the boat went over—I could not
spare a hand to save her—and struck hard against the gunwale.
When the boat righted and she got up again her forehead was
bleeding. On her white face the blood was like a black stain. But she
put her hand on mine and said: "I am not frightened, Marius. I love
you!"
Jan was close aboard again. As our way had deadened he had
overhauled us; and because he saw what had happened to my boat
he was able to bring his boat through the narrows without going
over.
"Marius! Marius! For God's sake, for Magali's sake, put about!" he
shouted. "It is the only chance to save her. Put about, I say!"
He was only a little way to leeward of us, but I barely made out his
words. The wind was roaring past us, and the waves were banging
like cannon on the rocks close by.
What he said was the truth, and I knew it. I knew that the gale was
only just beginning, and that no boat could live through it for
another hour. And then one of the devils loose on that All Souls Eve,
or perhaps it was my own devil inside of me, put a new evil thought
into my heart: making clear to me how I might get rid of Jan for
good and all, and without its ending in my losing my head or in my
losing Magali by being sent overseas. It was a chance, to be sure,
and full of danger. But just then I was ready for any danger or for
any chance.
testbankfan.com