510 views
0 0 votes

Examine the structure of the EMPLOYEES table:

EMPLOYEE_ID NUMBER Primary Key

FIRST_NAME VARCHAR2(25)

LAST_NAME VARCHAR2(25)

Assume all the following four statements are executed in the same sequence order.

S1: INSERT INTO employees (employee_id) VALUES (1000);

S2: INSERT INTO employees VALUES (‘1000’,‘John’,NULL); 
S3: INSERT INTO employees (employee_id, first_name, last_name) VALUES ( 1000, ‘John’,‘’);

S4: INSERT INTO employees(first_name,last_name, employee_id) VALUES ( 1000, ‘John’,‘Smith’); 

Which statement will not insert a row into the table?

 

→S2 won’t execute as we are trying to make primary key value as NuLL. But isn’t S4 also invalid?

Please log in or register to answer this question.

Position:
Show:

Related questions

4 4 votes
1 1 answer
189
189 views
GO Classes asked Sep 3
189 views
Consider the relation$\text{Student(sid,\ name,\ age)}$where the attributes occur in the schema in the order shown.Which of the following statements correctly inserts the...
0 0 votes
0 0 answers
445
445 views
Chhotu asked Dec 11, 2017
445 views
Hi Guys,In what situation Update, Delete and Insert operation could be performed via view ? Please provide some kind of proof to support your answer. It will be really he...
0 0 votes
0 0 answers
496
496 views
0 0 votes
1 1 answer
111
111 views
GO Classes asked 6 days ago
111 views
The database contains relations $\mathrm{animals}$ and $\mathrm{visits}$, with $\mathrm{aid}$ identifying an animal.Which SQL query returns the names of animals that visi...