Database schema:
CREATE TABLE Document_Subsets (
  Document_Subset_ID NUMBER PRIMARY KEY,
  Document_Subset_Name TEXT,
  Document_Subset_Details TEXT
);
CREATE TABLE Collection_Subsets (
  Collection_Subset_ID NUMBER PRIMARY KEY,
  Collection_Subset_Name TEXT,
  Collecrtion_Subset_Details TEXT
);
CREATE TABLE Document_Objects (
  Document_Object_ID NUMBER PRIMARY KEY,
  Parent_Document_Object_ID NUMBER,
  Owner TEXT,
  Description TEXT,
  Other_Details TEXT
);
CREATE TABLE Collections (
  Collection_ID NUMBER PRIMARY KEY,
  Parent_Collection_ID NUMBER,
  Collection_Name TEXT,
  Collection_Description TEXT
);
CREATE TABLE Documents_in_Collections (
  Document_Object_ID NUMBER PRIMARY KEY,
  Collection_ID NUMBER,
  FOREIGN KEY (Collection_ID) REFERENCES Collections(Collection_ID),
  FOREIGN KEY (Document_Object_ID) REFERENCES Document_Objects(Document_Object_ID)
);
CREATE TABLE Document_Subset_Members (
  Document_Object_ID NUMBER PRIMARY KEY,
  Related_Document_Object_ID NUMBER,
  Document_Subset_ID NUMBER,
  FOREIGN KEY (Document_Subset_ID) REFERENCES Document_Subsets(Document_Subset_ID),
  FOREIGN KEY (Related_Document_Object_ID) REFERENCES Document_Objects(Document_Object_ID),
  FOREIGN KEY (Document_Object_ID) REFERENCES Document_Objects(Document_Object_ID)
);
CREATE TABLE Collection_Subset_Members (
  Collection_ID NUMBER PRIMARY KEY,
  Related_Collection_ID NUMBER,
  Collection_Subset_ID NUMBER,
  FOREIGN KEY (Collection_Subset_ID) REFERENCES Collection_Subsets(Collection_Subset_ID),
  FOREIGN KEY (Related_Collection_ID) REFERENCES Collections(Collection_ID),
  FOREIGN KEY (Collection_ID) REFERENCES Collections(Collection_ID)
);

Question: For ever collection named 'Best', what is the name and id of the one with the most documents, and how many documents does it have?
SQL: SELECT T1.Collection_Name ,  T1.Collection_ID ,  count(*) FROM Collections AS T1 JOIN Documents_in_Collections AS T2 ON T1.Collection_ID = T2.Collection_ID WHERE T1.Collection_Name = "Best" GROUP BY T1.Collection_ID ORDER BY count(*) DESC LIMIT 1;

Question: What are the document subset names?
SQL: SELECT Document_Subset_Name FROM Document_Subsets;

Question: What is the owner of document with the Description 'Braeden Collection'?
SQL: SELECT OWNER FROM Document_Objects WHERE Description  =  'Braeden Collection'

Question: What collection details are there on the subset named 'Top collection'?
SQL: SELECT Collecrtion_Subset_Details FROM Collection_Subsets WHERE Collection_Subset_Name = "Top collection";

Question: List document id of all documents.
SQL: SELECT Document_Object_ID FROM Document_Objects;

Question: What are the ids of the documents that have more than one child?
SQL: SELECT T2.Document_Object_ID FROM Document_Objects AS T1 JOIN Document_Objects AS T2 ON T1.Parent_Document_Object_ID = T2.Document_Object_ID GROUP BY T2.Document_Object_ID HAVING count(*)  >  1;

Question: What are the different document object ids in the subset named 'Best for 2000' and in the collection named 'Best'?
SQL: SELECT DISTINCT T1.Document_Object_ID FROM Document_Subset_Members AS T1 JOIN Document_Subsets AS T2 ON T1.Document_Subset_ID =  T2.Document_Subset_ID JOIN Documents_in_Collections AS T3 ON T1.Document_Object_ID  =  T3.Document_Object_ID JOIN Collections AS T4 ON T3.Collection_ID  =  T4.Collection_ID WHERE T2.Document_Subset_Name = "Best for 2000" AND T4.Collection_Name = "Best";

Question: What is the subset id, name, and number of different documents for each subset?
SQL: SELECT T1.Document_Subset_ID ,  T2.Document_Subset_Name , count(DISTINCT T1.Document_Object_ID) FROM Document_Subset_Members AS T1 JOIN Document_Subsets AS T2 ON T1.Document_Subset_ID =  T2.Document_Subset_ID GROUP BY T1.Document_Subset_ID;

Question: List the name of all collections.
SQL: SELECT Collection_Name FROM Collections;

Question: What is the name of the parent collection of the collection named Nice?
SQL: SELECT T2.Collection_Name FROM Collections AS T1 JOIN Collections AS T2 ON T1.Parent_Collection_ID = T2.Collection_ID WHERE T1.Collection_Name = "Nice";

Question: What is the number of documents in the collection named 'Best'?
SQL: SELECT count(*) FROM Collections AS T1 JOIN Documents_in_Collections AS T2 ON T1.Collection_ID = T2.Collection_ID WHERE T1.Collection_Name = "Best";

Question: What are the collection descriptions that are named as 'Best'?
SQL: SELECT Collection_Description FROM Collections WHERE Collection_Name = "Best";

Question: Which document subset has most of number of distinct documents ? List subset id , name and number of documents .
SQL: select t1.document_subset_id ,  t2.document_subset_name , count(distinct t1.document_object_id) from document_subset_members as t1 join document_subsets as t2 on t1.document_subset_id =  t2.document_subset_id group by t1.document_subset_id order by count(*) desc limit 1;

Question: List all document subsets of documents that related to each document id. List the name of document subset and the document id.
SQL: SELECT DISTINCT T3.Document_Subset_Name ,  T1.Document_Object_ID FROM Document_Subset_Members AS T1 JOIN Document_Subset_Members  AS T2 ON T1.Related_Document_Object_ID = T2.Document_Object_ID JOIN Document_Subsets AS T3 ON T2.Document_Subset_ID =  T3.Document_Subset_ID