Changes in complementary tutorial time
Due to memorial day, the complementary SQL tutorial (tutorial 5) will be held in 27/5 at 15:30 in Taub 5
The Course Staff
An updated version to HW1 was uploaded
|Changes are marked in yellow.|
Please make sure you submit the right version!
Changes is complementary lecture and tutorial times
The complementary lecture will be held in 30.4 at 16:30-18:30 followed by the complementary tutorial. Both in Taub 2
The Course Staff
HW1 is online
|Submission is May 9th in the course cell.|
If you have any questions please contact Liat.
Happy Passover and enjoy your vacation!
Shoval's office hour is canceled for this week
A guide for local PostgreSQL installation can be found under course materials->additional files.
We will use it on HW2, and you are encouraged to use it on HW1, to verify your answers.
The course staff
Complementary Tutorial (3) for Monday's group on Thursday (6/4)
|A complementary tutorial (3) will be held on Thursday (6/4) on Taub 8, 11:30-12:30.|
Complementary Lecture on Sunday (2/4)
|A complementary lecture will be held on Sunday April 2nd on Taub 4.|
The lecture will start at 16:30 and will end approximately on 18:00 (without a break).
Some answers and clarifications from tutorial 1
here are some corrections and answers to questions I was been asked in tut.1 and I gave a perhaps misleading or unclear answer, or I said I'll clarify those questions in an announcement :
1. can One just insert or delete rows from view? - if you have the right permissions (e.g. superuser or admin), actually, yes. while the view might filter out what you have inserted or deleted. The manipulation is done on the underlying table.
2. duplicate a table with inserting it to itself - you cannot duplicate a table with a PK, while a table without PK you can ( you can create a table without PK).
3. DECIMAL(precision, scale) - p is the maximum number of all digits (both sides of the decimal point), s is the maximum number of digits after the decimal point
4. insertion fields order - if I understood the question right (if not, the student who asked is more then welcome to email me about that) the question is about If one can insert a value to a field which is not in the order of the appearance of fields in the schema - the answer is yes. the 2 lists you are providing to the INSERT should be in the same length, and the first one (lets call it FieldsList) should have the names of the fields you are giving a specific data for, in the value list (ValuesList). for an iterator 0<=I<=lists size , when inserting new data the value in ValuesList[I] is validated against the field definition of FieldsList[I]. if every value is ok and you are ok with table constrains (NULLS, Unique, Keys, etc..) , the new values will be inserted to their fields. there is no (need to have) enforcement about the order of the fields names in FeildsList compared to the order they are appearing in the schema. for example (lets assume that the Books table from tut1 is allowing NULL values except its PK) this INSERT command is fine :
INSERT INTO Books (Year, Book_id) VALUES ( 5, 6)
this will create a book with id=6 and year=5, while all other fields are NULL. as you can see, this is done without the consideration of the appearance of the fields in the schema itself (where Book_id is "before" Year).
5. can I call a column "SELECT" - yes, you should you SELECT "SELECT" FROM TableName in order to query
6. can one delete a referenced primary key column - no.
Changes during the semester
|All of the changes in lectures/tutorials appear under events. Please make sure you are updated with all of them.|
The tutorial on Monday 27/3 is cancelled.
Tuesday 15:30 recitation's location update
The recitation has changed to Fishbach 505.
The Course staff
Welcome to Database Systems Course, Cancelled Lecture
Welcome to Database Systems Course!
The lecture on Tuesday next week (21/03) is cancelled,
but recitations will be given normally.
The Course staff