Question: SQL / R programming question: a) Add the tuple 'D4, COMPLAINTS, E3' to the table 'DEPARTMENT'. b) Create a new department relation, called NEW_DEPARTMENT that

SQL / R programming question:

a) Add the tuple 'D4, COMPLAINTS, E3' to the table 'DEPARTMENT'.

b) Create a new department relation, called NEW_DEPARTMENT that includes the tuple added in a)

c) Check that NEW_DEPARTMENT exists in your database

d) Delete NEW_DEPARTMENT

e) Check that NEW_DEPARTMENT has been deleted

IMPORTANT INFO:

Here's my relation 'DEPARTMENT':

DEPT_NO,NAME,MANAGER D1,Accounts,E1 D2,Stores,E3 D3,Sales,null

Here is what I have done so far:

NEW_DEPARTMENT<-dbSendQuery(amydb2, 'INSERT INTO DEPARTMENT1 VALUES ("D4","COMPLAINTS","E3")') # My database is named 'amydb2'. Relation department is named 'DEPARTMENT1'.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!