If it is unique (such as automatic ID, primary key or unique index), it is used to uniquely identify each book sales record;
If it is not unique (there is no index or duplicate index is allowed), it can be used to identify the classification of book sales records.
According to the attached figure, this field is most likely to belong to "automatic ID". If so, it is used to uniquely identify the sales record of each book.
2) The title actually requires the respondent to find the corresponding "Book ID" in the "Books" list according to the title, and then insert it into the "Book Sales" list.
Suppose the ID field in the Book Sales table is an automatic ID. For the automatic ID system, when adding a record, it will automatically store a unique self-increasing number, without manual input (in fact, you can't manually add it to the automatic ID field).
According to the existing records in the book table, you can actually add the records in the book sales table as follows (the ID field is automatically added by the system):
Quantity Sales Date Employee ID Book ID
23 2004-4-4 1 1
45 2004-2-4 1 2
65 2004- 1-5 2 5
Run SQL statement to add (assuming the data types of employee ID and book ID are text)
Inserted into the book (quantity, sales date, employee ID, book ID) value (23, # 2004-4-4 #,' 1','1');
Inserted into the book (quantity, sales date, employee ID, book ID) value (45, # 2004-2-4 #,' 1',' 2');
Inserted into the book (quantity, sales date, employee ID, book ID) value (65, # 2004- 1-5 #,' 2',' 5');
Note: If the ID field is not an automatic ID, you need to specify the corresponding ID value, which cannot be ignored.