exam questions

Exam 1z0-061 All Questions

View all questions & answers for the 1z0-061 exam

Exam 1z0-061 topic 1 question 73 discussion

Actual exam question from Oracle's 1z0-061
Question #: 73
Topic #: 1
[All 1z0-061 Questions]

Which statement adds a column called salary to the employees table having 100 rows, which cannot contain null?

  • A. Option A
  • B. Option B
  • C. Option C
  • D. Option D C
Show Suggested Answer Hide Answer
Suggested Answer: Explanation 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
webdata
2 years, 11 months ago
Selected Answer: A
The 100 existing rows is already here, but constraint focus on news rows. Correct answer is A.
upvoted 1 times
...
bongtrader
3 years, 11 months ago
C is the correct answer. Checked by using Oracle Live SQL. At first, it appears A is the correct answer. It is the correct answer if our employees table was empty. However, re-reading the question, it says the table has 100 rows. Therefore, option A when run on a table that has data gives an error - "ORA-01758: table must be empty to add mandatory (NOT NULL) column ". on the other hand, option C works perfectly well if the table has 0 rows or 100 rows.
upvoted 3 times
...
Brasil
4 years, 7 months ago
Correct answer is C, why a table needs to be empty to add the constraint not null.
upvoted 1 times
...
Lif
5 years, 2 months ago
A is the correct answer. C run but the default value is 0.
upvoted 1 times
...
cnyce
5 years, 7 months ago
What is the correct answer here? C? or maybe A?
upvoted 1 times
Andy840
5 years, 4 months ago
Correct answer: A
upvoted 3 times
luizyto
5 years, 3 months ago
Correct answer is C: a) SQL> alter table product 2 add salary number (8,2) not null; alter table product * ERROR at line 1: ORA-01758: table must be empty to add mandatory (NOT NULL) column c) SQL> alter table product 2 add 3 salary number(8,2) default 0 not null;
upvoted 1 times
...
...
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago