### Database Schema:
CREATE TABLE offices (
	officeCode	TEXT	NOT NULL	PRIMARY KEY,
	city	TEXT	NOT NULL,
	phone	TEXT	NOT NULL,
	addressLine1	TEXT	NOT NULL,
	addressLine2	TEXT	NULL,
	state	TEXT	NULL,
	country	TEXT	NOT NULL,
	postalCode	TEXT	NOT NULL,
	territory	TEXT	NOT NULL
);

CREATE TABLE orders (
	orderNumber	INTEGER	NOT NULL	PRIMARY KEY,
	orderDate	DATE	NOT NULL,
	requiredDate	DATE	NOT NULL,
	shippedDate	DATE	NULL,
	status	TEXT	NOT NULL,
	comments	TEXT	NULL,
	customerNumber	INTEGER	NOT NULL,
	foreign key (customerNumber) references customers (customerNumber)
);

CREATE TABLE customers (
	customerNumber	INTEGER	NOT NULL	PRIMARY KEY,
	customerName	TEXT	NOT NULL,
	contactLastName	TEXT	NOT NULL,
	contactFirstName	TEXT	NOT NULL,
	phone	TEXT	NOT NULL,
	addressLine1	TEXT	NOT NULL,
	addressLine2	TEXT	NULL,
	city	TEXT	NOT NULL,
	state	TEXT	NULL,
	postalCode	TEXT	NULL,
	country	TEXT	NOT NULL,
	salesRepEmployeeNumber	INTEGER	NULL,
	creditLimit	REAL	NULL,
	foreign key (salesRepEmployeeNumber) references employees (employeeNumber)
);

CREATE TABLE orderdetails (
	orderNumber	INTEGER	NOT NULL	PRIMARY KEY,
	productCode	TEXT	NOT NULL	PRIMARY KEY,
	quantityOrdered	INTEGER	NOT NULL,
	priceEach	REAL	NOT NULL,
	orderLineNumber	INTEGER	NOT NULL,
	foreign key (orderNumber) references orders (orderNumber),
	foreign key (productCode) references products (productCode)
);

CREATE TABLE products (
	productCode	TEXT	NOT NULL	PRIMARY KEY,
	productName	TEXT	NOT NULL,
	productLine	TEXT	NOT NULL,
	productScale	TEXT	NOT NULL,
	productVendor	TEXT	NOT NULL,
	productDescription	TEXT	NOT NULL,
	quantityInStock	INTEGER	NOT NULL,
	buyPrice	REAL	NOT NULL,
	MSRP	REAL	NOT NULL,
	foreign key (productLine) references productlines (productLine)
);

CREATE TABLE payments (
	customerNumber	INTEGER	NOT NULL	PRIMARY KEY,
	checkNumber	TEXT	NOT NULL	PRIMARY KEY,
	paymentDate	DATE	NOT NULL,
	amount	REAL	NOT NULL,
	foreign key (customerNumber) references customers (customerNumber)
);

CREATE TABLE productlines (
	productLine	TEXT	NOT NULL	PRIMARY KEY,
	textDescription	TEXT	NULL,
	htmlDescription	TEXT	NULL,
	image	BLOB	NULL
);

CREATE TABLE employees (
	employeeNumber	INTEGER	NOT NULL	PRIMARY KEY,
	lastName	TEXT	NOT NULL,
	firstName	TEXT	NOT NULL,
	extension	TEXT	NOT NULL,
	email	TEXT	NOT NULL,
	officeCode	TEXT	NOT NULL,
	reportsTo	INTEGER	NULL,
	jobTitle	TEXT	NOT NULL,
	foreign key (officeCode) references offices (officeCode),
	foreign key (reportsTo) references employees (employeeNumber)
);

### User's Query:
How many French customers does Gerard Hernandez take care of?

### Extra Knowledge:
Gerakd Hermandez is an employee; French customer refers to customer from France where country = 'France'
SELECT COUNT(t1.customerNumber) FROM customers AS t1 INNER JOIN employees AS t2 ON t1.salesRepEmployeeNumber = t2.employeeNumber WHERE t1.country = 'France' AND t2.firstName = 'Gerard' AND t2.lastName = 'Hernandez'