Database schema:
CREATE TABLE Employee (
  EmployeeID NUMBER PRIMARY KEY,
  Name TEXT,
  Position TEXT,
  Salary NUMBER,
  Remarks TEXT
);
CREATE TABLE Planet (
  PlanetID NUMBER PRIMARY KEY,
  Name TEXT,
  Coordinates NUMBER
);
CREATE TABLE Shipment (
  ShipmentID NUMBER PRIMARY KEY,
  Date TIME,
  Manager NUMBER,
  Planet NUMBER,
  FOREIGN KEY (Planet) REFERENCES Planet(PlanetID),
  FOREIGN KEY (Manager) REFERENCES Employee(EmployeeID)
);
CREATE TABLE Has_Clearance (
  Employee NUMBER PRIMARY KEY,
  Planet NUMBER,
  Level NUMBER,
  FOREIGN KEY (Planet) REFERENCES Planet(PlanetID),
  FOREIGN KEY (Employee) REFERENCES Employee(EmployeeID)
);
CREATE TABLE Client (
  AccountNumber NUMBER PRIMARY KEY,
  Name TEXT
);
CREATE TABLE Package (
  Shipment NUMBER PRIMARY KEY,
  PackageNumber NUMBER,
  Contents TEXT,
  Weight NUMBER,
  Sender NUMBER,
  Recipient NUMBER,
  FOREIGN KEY (Recipient) REFERENCES Client(AccountNumber),
  FOREIGN KEY (Sender) REFERENCES Client(AccountNumber),
  FOREIGN KEY (Shipment) REFERENCES Shipment(ShipmentID)
);

Question: Who sent most number of packages? List client name and number of packages sent by that client.
SQL: SELECT T2.Name ,  count(*) FROM PACKAGE AS T1 JOIN Client AS T2 ON T1.Sender  =  T2.AccountNumber GROUP BY T1.Sender ORDER BY count(*) DESC LIMIT 1;

Question: What are the coordinates of the planet named Mars?
SQL: SELECT Coordinates FROM Planet WHERE Name  =  "Mars";

Question: What is the average salary of all intern jobs?
SQL: SELECT avg(Salary) FROM Employee WHERE POSITION  =  "Intern";

Question: What are the employees's names for those that have salaries between 5000 and 10000?
SQL: SELECT Name FROM Employee WHERE Salary BETWEEN 5000 AND 10000

Question: Which planets that have exact one employee has clearance? List planets' name.
SQL: SELECT T3.Name FROM Has_Clearance AS T1 JOIN Employee AS T2 ON T1.Employee = T2.EmployeeID JOIN Planet AS T3 ON T1.Planet = T3.PlanetID GROUP BY T1.Planet HAVING count(*)  =  1;

Question: What is the clearance level of a physician?
SQL: SELECT T1.Level FROM Has_Clearance AS T1 JOIN Employee AS T2 ON T1.Employee = T2.EmployeeID WHERE T2.position  =  "Physician";

Question: Who sent more than one packages? List the client's name.
SQL: SELECT T2.Name ,  count(*) FROM PACKAGE AS T1 JOIN Client AS T2 ON T1.Sender  =  T2.AccountNumber GROUP BY T1.Sender HAVING count(*)  >  1;

Question: What are the names of all planets tjat have a total shipment weight greater than 30?
SQL: SELECT T3.Name FROM PACKAGE AS T1 JOIN Shipment AS T2 ON T1.Shipment = T2.ShipmentID JOIN Planet AS T3 ON T2.Planet = T3.PlanetID GROUP BY T2.Planet HAVING sum(T1.Weight)  >  30;

Question: What is the total shipments in each planet? List the planet name and total shipments.
SQL: SELECT T2.Name ,  count(*) FROM Shipment AS T1 JOIN Planet AS T2 ON T1.Planet = T2.PlanetID GROUP BY T1.Planet;

Question: What is the smallest number of packages received and by whom ?
SQL: select t2.name ,  count(*) from package as t1 join client as t2 on t1.recipient  =  t2.accountnumber group by t1.recipient order by count(*) limit 1;

Question: Who receieved the heaviest package?
SQL: SELECT T2.Name FROM PACKAGE AS T1 JOIN Client AS T2 ON T1.Recipient  =  T2.AccountNumber ORDER BY T1.Weight DESC LIMIT 1

Question: What are all the different package numbers that Leo Wong sent or received?
SQL: SELECT DISTINCT T1.PackageNumber FROM PACKAGE AS T1 JOIN Client AS T2 ON T1.Sender  =  T2.AccountNumber OR T1.Recipient  =  T2.AccountNumber WHERE T2.Name = "Leo Wong"

Question: What is the name of the planet with the most shipments?
SQL: SELECT T2.Name FROM Shipment AS T1 JOIN Planet AS T2 ON T1.Planet = T2.PlanetID GROUP BY T1.Planet ORDER BY count(*) DESC LIMIT 1;

Question: what is the total package weight for each planet, list its name ?
SQL: select t3.name ,  sum(t1.weight) from package as t1 join shipment as t2 on t1.shipment = t2.shipmentid join planet as t3 on t2.planet = t3.planetid group by t2.planet;

Question: What are the names of all planets with one employee that has clearance?
SQL: SELECT T3.Name FROM Has_Clearance AS T1 JOIN Employee AS T2 ON T1.Employee = T2.EmployeeID JOIN Planet AS T3 ON T1.Planet = T3.PlanetID GROUP BY T1.Planet HAVING count(*)  =  1;

Question: What are the number of packages sent by Zapp Brannigan and shipped on the Omicron Persei 8?
SQL: SELECT T1.PackageNumber FROM PACKAGE AS T1 JOIN Client AS T2 ON  T1.Sender = T2.AccountNumber JOIN Shipment AS T3 ON T1.Shipment = T3.ShipmentID JOIN Planet AS T4 ON T3.Planet = T4.PlanetID WHERE T2.Name = "Zapp Brannigan" AND T4.Name = "Omicron Persei 8";

Question: Which packages have weight between 10 and 30? List the package number and weight.
SQL: SELECT PackageNumber ,  Weight FROM PACKAGE WHERE Weight BETWEEN 10 AND 30;

Question: What is Turanga Leela's salary and position?
SQL: SELECT Salary ,  POSITION FROM Employee WHERE Name  =  "Turanga Leela";